public static String getDefaultRemoteHomeImplClassName(EjbDescriptor desc) { //IASRI 4725194 return desc.getEjbClassName() + REMOTE_SUFFIX; return desc.getEjbImplClassName() + REMOTE_SUFFIX; }
public static String getDefaultEJBObjectImplClassName(EjbDescriptor desc) { //IASRI 4725194 return desc.getEjbClassName() + REMOTE_SUFFIX; return desc.getEjbImplClassName() + REMOTE_SUFFIX; }
/** * Return the EjbCMPEntityDescriptor for a bean * for the given classname. * It is assumed that there is a 1-to-1 mapping * from class to descriptor. * This is called at runtime from the Persistence Manager. */ public EjbCMPEntityDescriptor getCMPDescriptorFor(String className) { synchronized(cmpDescriptorsLock) { if (cmpDescriptors == null) { cmpDescriptors = new HashMap(); for (EjbBundleDescriptor bundle : getBundleDescriptors(EjbBundleDescriptor.class)) { for (EjbDescriptor ejb : bundle.getEjbs()) { if (ejb instanceof EjbCMPEntityDescriptor) cmpDescriptors.put(ejb.getEjbImplClassName(), ejb); } } } return (EjbCMPEntityDescriptor) cmpDescriptors.get(className); } }
public InterceptorManager(Logger _logger, BaseContainer container, Class[] lcAnnotationClasses, String[] pre30LCMethodNames) throws Exception { this._logger = _logger; this.container = container; this.lcAnnotationClasses = lcAnnotationClasses; this.pre30LCMethodNames = pre30LCMethodNames; ejbDesc = container.getEjbDescriptor(); loader = container.getClassLoader(); beanClassName = ejbDesc.getEjbImplClassName(); this.beanClass = loader.loadClass(beanClassName); frameworkInterceptors = ejbDesc.getFrameworkInterceptors(); buildEjbInterceptorChain(); if (_logger.isLoggable(Level.FINE)) { _logger.log(Level.FINE, "InterceptorManager: " + toString()); } }
private void validateEjbProducer( Class annotatedClass, AnnotatedField annotatedField, List<InjectionCapable> injectionResources ) { EJB ejbAnnotation = annotatedField.getAnnotation(EJB.class); if ( ejbAnnotation != null ) { String lookupName = getLookupName(annotatedClass, annotatedField, injectionResources); EjbDescriptor foundEjb = null; Collection<EjbDescriptor> ejbs = deployment.getDeployedEjbs(); for ( EjbDescriptor oneEjb : ejbs ) { String jndiName = oneEjb.getJndiName(); if (lookupName.contains(jndiName)) { foundEjb = oneEjb; break; } } if ( foundEjb != null ) { String className = foundEjb.getEjbImplClassName(); try { Class clazz = Class.forName( className, false, annotatedClass.getClassLoader() ); validateResourceClass(annotatedField, clazz); } catch (ClassNotFoundException ignore) { } } } }
/** * Return the ordered list of interceptor info for AroundTimeout behavior * of a particular business method. This list *does* include the info * on any bean class interceptor. If present, this would always be the * last element in the list because of the precedence defined by the spec. */ public List<EjbInterceptor> getAroundTimeoutInterceptors (MethodDescriptor businessMethod) { LinkedList<EjbInterceptor> aroundTimeoutInterceptors = new LinkedList<EjbInterceptor>(); List<EjbInterceptor> classOrMethodInterceptors = getClassOrMethodInterceptors(businessMethod); for (EjbInterceptor next : classOrMethodInterceptors) { if (next.getAroundTimeoutDescriptors().size() > 0) { aroundTimeoutInterceptors.add(next); } } if (hasAroundTimeoutMethod()) { EjbInterceptor interceptorInfo = new EjbInterceptor(); interceptorInfo.setFromBeanClass(true); interceptorInfo.addAroundTimeoutDescriptors(getAroundTimeoutDescriptors()); interceptorInfo.setInterceptorClassName(getEjbImplClassName()); aroundTimeoutInterceptors.add(interceptorInfo); } return aroundTimeoutInterceptors; }
/** * Return the ordered list of interceptor info for AroundInvoke behavior * of a particular business method. This list *does* include the info * on any bean class interceptor. If present, this would always be the * last element in the list because of the precedence defined by the spec. */ public List<EjbInterceptor> getAroundInvokeInterceptors (MethodDescriptor businessMethod) { LinkedList<EjbInterceptor> aroundInvokeInterceptors = new LinkedList<EjbInterceptor>(); List<EjbInterceptor> classOrMethodInterceptors = getClassOrMethodInterceptors(businessMethod); for (EjbInterceptor next : classOrMethodInterceptors) { if (next.getAroundInvokeDescriptors().size() > 0) { aroundInvokeInterceptors.add(next); } } if (hasAroundInvokeMethod()) { EjbInterceptor interceptorInfo = new EjbInterceptor(); interceptorInfo.setFromBeanClass(true); interceptorInfo.addAroundInvokeDescriptors(getAroundInvokeDescriptors()); interceptorInfo.setInterceptorClassName(getEjbImplClassName()); aroundInvokeInterceptors.add(interceptorInfo); } return aroundInvokeInterceptors; }
public DeployedEndpointData(String path, Application app, WebServiceEndpoint endpoint) { super(path, "", ""); this.appName = app.getAppName(); this.endpointName = endpoint.getEndpointName(); this.namespace = endpoint.getServiceName().getNamespaceURI(); this.serviceName = endpoint.getServiceName().getLocalPart(); QName pName = endpoint.getWsdlPort(); this.portName = (pName != null) ? pName.getLocalPart() : ""; this.implClass = endpoint.implementedByEjbComponent() ? endpoint.getEjbComponentImpl().getEjbImplClassName() : endpoint.getServletImplClass(); this.address = path; this.wsdl = address+"?wsdl"; this.tester = address+"?Tester"; this.implType = endpoint.implementedByEjbComponent() ? "EJB" : "SERVLET"; this.deploymentType = "109"; fillStatMap(); }
cl.loadClass(dd.getEjbImplClassName()); } catch (ClassNotFoundException ex) { _logger.log(Level.FINE,"ejb.classnotfound_exception",ex); ("generator.bean_class_not_found", "Bean class {0} not found ", new Object[] { dd.getEjbImplClassName()})); ibe.initCause(ex); throw ibe;
try { this.bean = cl.loadClass(dd.getEjbImplClassName()); } catch (ClassNotFoundException ex) { throw new InvalidBean(
ejbClass = loader.loadClass(ejbDescriptor.getEjbImplClassName());
(getEjbImplClassName()); callbackInterceptors.add(beanClassCallbackInfo);