binder.readFromDatabase(null, null, buildMapping(this));
}
static private Mapping buildMapping(final Configuration cfg) {
return new Mapping() {
/**
* Returns the identifier type of a mapped class
*/
public Type getIdentifierType(String persistentClass) throws MappingException {
PersistentClass pc = cfg.getClassMapping( persistentClass );