Examples of AnnotationProcessor


Examples of org.apache.juddi.v3.annotations.AnnotationProcessor

         *
         */
        public void unRegisterAnnotatedServices() {
                Map<String, UDDIClerk> clerks = clientConfig.getUDDIClerks();
                if (clerks.size() > 0) {
                        AnnotationProcessor ap = new AnnotationProcessor();
                        for (UDDIClerk clerk : clerks.values()) {
                                Collection<BusinessService> services = ap.readServiceAnnotations(
                                        clerk.getClassWithAnnotations(), clerk.getUDDINode().getProperties());
                                for (BusinessService businessService : services) {
                                        clerk.unRegisterService(businessService.getServiceKey(), clerk.getUDDINode().getApiNode());
                                }
                        }
View Full Code Here

Examples of org.apache.juddi.v3.annotations.AnnotationProcessor

         */
        public void unRegisterBindingsOfAnnotatedServices(boolean removeServiceWithNoBindingTemplates) {

                Map<String, UDDIClerk> clerks = clientConfig.getUDDIClerks();
                if (clerks.size() > 0) {
                        AnnotationProcessor ap = new AnnotationProcessor();
                        for (UDDIClerk clerk : clerks.values()) {
                                Collection<BusinessService> services = ap.readServiceAnnotations(
                                        clerk.getClassWithAnnotations(), clerk.getUDDINode().getProperties());
                                for (BusinessService businessService : services) {
                                        if (businessService.getBindingTemplates() != null) {
                                                List<BindingTemplate> bindingTemplates = businessService.getBindingTemplates().getBindingTemplate();
                                                for (BindingTemplate bindingTemplate : bindingTemplates) {
View Full Code Here

Examples of org.apache.sling.scripting.jsp.jasper.runtime.AnnotationProcessor

        try {
            if ( log.isDebugEnabled() ) {
                log.debug("Loading servlet " + jspUri);
            }
            servlet = (Servlet) ctxt.load().newInstance();
            AnnotationProcessor annotationProcessor = (AnnotationProcessor) config.getServletContext().getAttribute(AnnotationProcessor.class.getName());
            if (annotationProcessor != null) {
               annotationProcessor.processAnnotations(servlet);
               annotationProcessor.postConstruct(servlet);
            }
            // update dependents
            final List<String> oldDeps = this.dependents;
            if (servlet != null && servlet instanceof JspSourceDependent) {
                this.dependents = (List<String>) ((JspSourceDependent) servlet).getDependants();
View Full Code Here

Examples of org.apache.sling.scripting.jsp.jasper.runtime.AnnotationProcessor

                    if ( c != null ) {
                        c.removeGeneratedFiles();
                    }
                }
                theServlet.destroy();
                AnnotationProcessor annotationProcessor = (AnnotationProcessor) config.getServletContext().getAttribute(AnnotationProcessor.class.getName());
                if (annotationProcessor != null) {
                    try {
                        annotationProcessor.preDestroy(theServlet);
                    } catch (Exception e) {
                        // Log any exception, since it can't be passed along
                        log.error(Localizer.getMessage("jsp.error.file.not.found",
                               e.getMessage()), e);
                    }
View Full Code Here

Examples of org.apache.sling.scripting.jsp.jasper.runtime.AnnotationProcessor

                    Servlet servlet = null;
                   
                    try {
                        servletClass = ctxt.load();
                        servlet = (Servlet) servletClass.newInstance();
                        AnnotationProcessor annotationProcessor = (AnnotationProcessor) config.getServletContext().getAttribute(AnnotationProcessor.class.getName());
                        if (annotationProcessor != null) {
                           annotationProcessor.processAnnotations(servlet);
                           annotationProcessor.postConstruct(servlet);
                        }
                    } catch (IllegalAccessException e) {
                        throw new JasperException(e);
                    } catch (InstantiationException e) {
                        throw new JasperException(e);
View Full Code Here

Examples of org.apache.sling.scripting.jsp.jasper.runtime.AnnotationProcessor

    }

    public void destroy() {
        if (theServlet != null) {
            theServlet.destroy();
            AnnotationProcessor annotationProcessor = (AnnotationProcessor) config.getServletContext().getAttribute(AnnotationProcessor.class.getName());
            if (annotationProcessor != null) {
                try {
                    annotationProcessor.preDestroy(theServlet);
                } catch (Exception e) {
                    // Log any exception, since it can't be passed along
                    log.error(Localizer.getMessage("jsp.error.file.not.found",
                           e.getMessage()), e);
                }
View Full Code Here

Examples of org.apache.sling.scripting.jsp.jasper.runtime.AnnotationProcessor

                    Servlet servlet = null;
                   
                    try {
                        servletClass = ctxt.load();
                        servlet = (Servlet) servletClass.newInstance();
                        AnnotationProcessor annotationProcessor = (AnnotationProcessor) config.getServletContext().getAttribute(AnnotationProcessor.class.getName());
                        if (annotationProcessor != null) {
                           annotationProcessor.processAnnotations(servlet);
                           annotationProcessor.postConstruct(servlet);
                        }
                    } catch (IllegalAccessException e) {
                        throw new JasperException(e);
                    } catch (InstantiationException e) {
                        throw new JasperException(e);
View Full Code Here

Examples of org.apache.sling.scripting.jsp.jasper.runtime.AnnotationProcessor

    }

    public void destroy() {
        if (theServlet != null) {
            theServlet.destroy();
            AnnotationProcessor annotationProcessor = (AnnotationProcessor) config.getServletContext().getAttribute(AnnotationProcessor.class.getName());
            if (annotationProcessor != null) {
                try {
                    annotationProcessor.preDestroy(theServlet);
                } catch (Exception e) {
                    // Log any exception, since it can't be passed along
                    log.error(Localizer.getMessage("jsp.error.file.not.found",
                           e.getMessage()), e);
                }
View Full Code Here

Examples of org.evokit.ui.internal.model.AnnotationProcessor

      javaProjects = new IJavaProject[] { fProject };
    }

    List<IType> types = new ArrayList<IType>();
    for (IJavaProject project : javaProjects) {
      AnnotationProcessor processor = new AnnotationProcessor(project);
      Set<String> result = processor.getSubclassesForClass(fSuperclass);
      IType type = getType(fSuperclass.getName(), project);
      if (type != null) {
        types.add(type);
      }
      for (String name : result) {
View Full Code Here

Examples of org.gcontracts.common.spi.AnnotationProcessor

    private void handleClassNode(final ClassNode classNode)  {
        final List<AnnotationNode> annotationNodes = AnnotationUtils.hasMetaAnnotations(classNode, ContractElement.class.getName());

        for (AnnotationNode annotationNode : annotationNodes)  {
            final AnnotationProcessor annotationProcessor = createAnnotationProcessor(annotationNode);

            if (annotationProcessor != null && annotationNode.getMember(CLOSURE_ATTRIBUTE_NAME) instanceof ClassExpression)  {
                final ClassExpression closureClassExpression = (ClassExpression) annotationNode.getMember(CLOSURE_ATTRIBUTE_NAME);

                MethodCallExpression doCall = new MethodCallExpression(
                        new ConstructorCallExpression(closureClassExpression.getType(), new ArgumentListExpression(VariableExpression.THIS_EXPRESSION, VariableExpression.THIS_EXPRESSION)),
                        "doCall",
                        ArgumentListExpression.EMPTY_ARGUMENTS
                );
                doCall.setMethodTarget(closureClassExpression.getType().getMethods("doCall").get(0));

                final BooleanExpression booleanExpression = new BooleanExpression(doCall);
                booleanExpression.setSourcePosition(annotationNode);

                annotationProcessor.process(pci, pci.contract(), classNode, (BlockStatement) closureClassExpression.getNodeMetaData(AnnotationClosureVisitor.META_DATA_ORIGINAL_TRY_CATCH_BLOCK), booleanExpression);
            }
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.