@Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; EJBViewDescription that = (EJBViewDescription) o; // since the views are added to the component description, that should already be equal if (hasJNDIBindings != that.hasJNDIBindings) return false; if (methodIntf != that.methodIntf) return false; if (!getViewClassName().equals(that.getViewClassName())) return false; //we compare the components based on == //as you can have two components with the same name if (getComponentDescription() != that.getComponentDescription()) return false; return super.equals(o); }
@Override public int hashCode() { int result = methodIntf.hashCode(); result = 31 * result + (hasJNDIBindings ? 1 : 0); result = 31 * result + getViewClassName().hashCode(); result = 31 * result + getComponentDescription().getComponentName().hashCode(); return result; }
@Override protected InjectionSource createInjectionSource(final ServiceName serviceName, Value<ClassLoader> viewClassLoader, boolean appclient) { if(methodIntf != MethodIntf.REMOTE && methodIntf != MethodIntf.HOME) { return super.createInjectionSource(serviceName, viewClassLoader, appclient); } else { final EJBComponentDescription componentDescription = getComponentDescription(); final EEModuleDescription desc = componentDescription.getModuleDescription(); final String earApplicationName = desc.getEarApplicationName(); return new RemoteViewInjectionSource(serviceName, earApplicationName, desc.getModuleName(), desc.getDistinctName(), componentDescription.getComponentName(), getViewClassName() , componentDescription.isStateful(),viewClassLoader, appclient); } }
final EJBComponentDescription componentDescription = (EJBComponentDescription) description.getComponentDescription(); final EEModuleDescription moduleDescription = componentDescription.getModuleDescription(); final String earApplicationName = moduleDescription.getEarApplicationName();
@Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; EJBViewDescription that = (EJBViewDescription) o; // since the views are added to the component description, that should already be equal if (hasJNDIBindings != that.hasJNDIBindings) return false; if (methodIntf != that.methodIntf) return false; if (!getViewClassName().equals(that.getViewClassName())) return false; //we compare the components based on == //as you can have two components with the same name if (getComponentDescription() != that.getComponentDescription()) return false; return super.equals(o); }
@Override public int hashCode() { int result = methodIntf.hashCode(); result = 31 * result + (hasJNDIBindings ? 1 : 0); result = 31 * result + getViewClassName().hashCode(); result = 31 * result + getComponentDescription().getComponentName().hashCode(); return result; }
@Override protected InjectionSource createInjectionSource(final ServiceName serviceName, Value<ClassLoader> viewClassLoader) { if(methodIntf != MethodIntf.REMOTE && methodIntf != MethodIntf.HOME) { return super.createInjectionSource(serviceName, viewClassLoader); } else { final EJBComponentDescription componentDescription = getComponentDescription(); final EEModuleDescription desc = componentDescription.getModuleDescription(); final String earApplicationName = desc.getEarApplicationName(); return new RemoteViewInjectionSource(serviceName, earApplicationName, desc.getModuleName(), desc.getDistinctName(), componentDescription.getComponentName(), getViewClassName() , componentDescription.isStateful(),viewClassLoader); } }
final EJBComponentDescription componentDescription = (EJBComponentDescription) description.getComponentDescription(); final EEModuleDescription moduleDescription = componentDescription.getModuleDescription(); final String earApplicationName = moduleDescription.getEarApplicationName();