processEntityListeners(getJavaClass(), loader);
// Step 3 - process the entity class for lifecycle callback methods. Go
// through the mapped superclasses as well.
MetadataEntityListener listener = processEntityEventListener(loader);
if (! m_descriptor.excludeSuperclassListeners()) {
for (ClassAccessor mappedSuperclass : getMappedSuperclasses()) {
mappedSuperclass.processMappedSuperclassEventListener(listener, getJavaClass(), loader);
}
}
// Add the listener only if we actually found callback methods.
if (listener.hasCallbackMethods()) {
m_descriptor.setEntityEventListener(listener);
}
}