return Morphia.class;
}
@Override
protected Morphia createInstance() throws Exception {
Morphia m = new Morphia();
// lightweight wrapper around the JSR303 API Validation Extension
new MorphiaValidation().applyTo(m);
if (mapPackages != null) {
for (String packageName : mapPackages) {
m.mapPackage(packageName, ignoreInvalidClasses);
}
}
if (mapClasses != null) {
for (String entityClass : mapClasses) {
m.map(Class.forName(entityClass));
}
}
return m;
}