Package javax.ejb

Examples of javax.ejb.Init


                 * @Init
                 */
                for (Annotated<Method> method : sortMethods(annotationFinder.findMetaAnnotatedMethods(Init.class))) {
                    InitMethod initMethod = new InitMethod(method.get());

                    Init init = method.getAnnotation(Init.class);
                    if (init.value() != null && !init.value().equals("")) {
                        initMethod.setCreateMethod(init.value());
                    }

                    session.getInitMethod().add(initMethod);
                }

View Full Code Here


                 * @Init
                 */
                for (final Annotated<Method> method : sortMethods(annotationFinder.findMetaAnnotatedMethods(Init.class))) {
                    final InitMethod initMethod = new InitMethod(method.get());

                    final Init init = method.getAnnotation(Init.class);
                    if (init.value() != null && !init.value().equals("")) {
                        initMethod.setCreateMethod(init.value());
                    }

                    session.getInitMethod().add(initMethod);
                }

View Full Code Here

    }
   
    protected HandlerProcessingResult processAnnotation(AnnotationInfo ainfo,
            EjbContext[] ejbContexts) throws AnnotationProcessorException {

        Init init = (Init) ainfo.getAnnotation();

        for(EjbContext next : ejbContexts) {
           
            EjbSessionDescriptor sessionDescriptor =
                (EjbSessionDescriptor) next.getDescriptor();

            Method m = (Method) ainfo.getAnnotatedElement();

            // Check for matching method on home and/or local home interface.

            int numMatches = 0;

           
            String adaptedCreateMethodName = init.value();

            try {
                if( sessionDescriptor.isRemoteInterfacesSupported() ) {
                    addInitMethod(sessionDescriptor, m,
                                  adaptedCreateMethodName, false);
View Full Code Here

                 * @Init
                 */
                for (Annotated<Method> method : sortMethods(annotationFinder.findMetaAnnotatedMethods(Init.class))) {
                    InitMethod initMethod = new InitMethod(method.get());

                    Init init = method.getAnnotation(Init.class);
                    if (init.value() != null && !init.value().equals("")) {
                        initMethod.setCreateMethod(init.value());
                    }

                    session.getInitMethod().add(initMethod);
                }

View Full Code Here

/*  52 */     super(finder);
/*     */   }
/*     */
/*     */   public InitMethodMetaData create(Method method)
/*     */   {
/*  57 */     Init init = (Init)this.finder.getAnnotation(method, Init.class);
/*  58 */     if (init == null) {
/*  59 */       return null;
/*     */     }
/*  61 */     InitMethodMetaData metaData = new InitMethodMetaData();
/*  62 */     NamedMethodMetaData beanMethod = new NamedMethodMetaData();
/*  63 */     metaData.setBeanMethod(beanMethod);
/*  64 */     NamedMethodMetaData createMethod = new NamedMethodMetaData();
/*  65 */     metaData.setCreateMethod(createMethod);
/*     */
/*  67 */     String alternativeName = init.value().length() > 0 ? init.value() : method.getName();
/*     */
/*  70 */     if (method.getDeclaringClass().isInterface())
/*     */     {
/*  72 */       beanMethod.setMethodName(alternativeName);
/*  73 */       createMethod.setMethodName(method.getName());
View Full Code Here

                 * @Init
                 */
                for (Annotated<Method> method : sortMethods(annotationFinder.findMetaAnnotatedMethods(Init.class))) {
                    InitMethod initMethod = new InitMethod(method.get());

                    Init init = method.getAnnotation(Init.class);
                    if (init.value() != null && !init.value().equals("")) {
                        initMethod.setCreateMethod(init.value());
                    }

                    session.getInitMethod().add(initMethod);
                }

View Full Code Here

    }   
       
    protected HandlerProcessingResult processAnnotation(AnnotationInfo ainfo,
            EjbContext[] ejbContexts) throws AnnotationProcessorException {

        Init init = (Init) ainfo.getAnnotation();

        for(EjbContext next : ejbContexts) {
           
            EjbSessionDescriptor sessionDescriptor =
                (EjbSessionDescriptor) next.getDescriptor();

            Method m = (Method) ainfo.getAnnotatedElement();

            // Check for matching method on home and/or local home interface.

            int numMatches = 0;

           
            String adaptedCreateMethodName = init.value();

            try {
                if( sessionDescriptor.isRemoteInterfacesSupported() ) {
                    addInitMethod(sessionDescriptor, m,
                                  adaptedCreateMethodName, false);
View Full Code Here

                 * @Init
                 */
                for (Annotated<Method> method : sortMethods(annotationFinder.findMetaAnnotatedMethods(Init.class))) {
                    InitMethod initMethod = new InitMethod(method.get());

                    Init init = method.getAnnotation(Init.class);
                    if (init.value() != null && !init.value().equals("")) {
                        initMethod.setCreateMethod(init.value());
                    }

                    session.getInitMethod().add(initMethod);
                }

View Full Code Here

TOP

Related Classes of javax.ejb.Init

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.