if (log.isDebugEnabled()) {
log.debug("return_type=" + return_type);
}
if (return_type == null) {
throw new XDocletException(Translator.getString(XDocletModulesEjbMessages.class, XDocletModulesEjbMessages.ASK_FOR_BEAN_FROM_NULL_INTERFACE, new String[]{return_type}));
}
for (Iterator i = classes.iterator(); i.hasNext(); ) {
XClass clazz = (XClass) i.next();
if (log.isDebugEnabled()) {
log.debug("clazz=" + clazz);
}
if (EntityTagsHandler.isEntity(clazz)) {
String remote_intf_name = getComponentInterface("remote", clazz);
String local_intf_name = getComponentInterface("local", clazz);
if (log.isDebugEnabled()) {
log.debug("remote_intf_name=" + remote_intf_name);
log.debug("local_intf_name=" + local_intf_name);
}
if (return_type.equals(remote_intf_name) || return_type.equals(local_intf_name)) {
if (log.isDebugEnabled()) {
log.debug("Found! beanClassNameFromInterfaceName returns with: " + clazz.getQualifiedName());
}
return clazz.getQualifiedName();
}
}
}
if (log.isDebugEnabled()) {
log.warn("NOT FOUND! bean class coreesponding to IF " + return_type);
}
throw new XDocletException(Translator.getString(XDocletModulesEjbMessages.class, XDocletModulesEjbMessages.BEAN_CLASS_NOT_FOUND_FOR_INTERFACE, new String[]{return_type}));
}