Examples of JAnnotation


Examples of com.google.gwt.dev.jjs.ast.JAnnotation

      } else if (value instanceof AnnotationBinding) {
        AnnotationBinding annotationBinding = (AnnotationBinding) value;
        ReferenceBinding annotationType = annotationBinding.getAnnotationType();
        JInterfaceType type = (JInterfaceType) typeMap.tryGet(annotationType);
        JAnnotation toReturn;
        if (type != null) {
          toReturn = new JAnnotation(info, type);
        } else {
          JInterfaceType external = getOrCreateExternalType(info,
              annotationType.compoundName);
          toReturn = new JAnnotation(info, external);
        }

        // Load the properties for the annotation value
        processAnnotationProperties(info, toReturn,
            annotationBinding.getElementValuePairs());
View Full Code Here

Examples of org.apache.cxf.tools.common.model.JAnnotation

        asyncHandler.setClassName(getAsyncClassName(method, "AsyncHandler"));
        asyncHandler.setStyle(JavaType.Style.IN);
       
        callbackMethod.addParameter(asyncHandler);
       
        JAnnotation asyncHandlerAnnotation = new JAnnotation(WebParam.class);
        asyncHandlerAnnotation.addElement(new JAnnotationElement("name", "asyncHandler"));
        asyncHandlerAnnotation.addElement(new JAnnotationElement("targetNamespace", ""));
        asyncHandler.addAnnotation("WebParam", asyncHandlerAnnotation);               

        method.getInterface().addImport("javax.jws.WebParam");
        method.getInterface().addMethod(callbackMethod);
    }
View Full Code Here

Examples of org.apache.cxf.tools.common.model.JAnnotation

                    processor.processMethod(jm, bop.getOperationInfo(), jaxwsBinding);

                }

                if (headerType == this.resultHeader) {
                    JAnnotation resultAnno = jm.getAnnotationMap().get("WebResult");
                    if (resultAnno != null) {
                        resultAnno.addElement(new JAnnotationElement("header", true, true));
                    }
                }
                processParameter(jm, bop);
            }
        }
View Full Code Here

Examples of org.apache.cxf.tools.common.model.JAnnotation

        }
    }

    private void setParameterAsHeader(JavaParameter parameter) {
        parameter.setHeader(true);
        JAnnotation parameterAnnotation = parameter.getAnnotation("WebParam");
        parameterAnnotation.addElement(new JAnnotationElement("header", true, true));
        parameterAnnotation.addElement(new JAnnotationElement("name",
                                                                     parameter.getQName().getLocalPart()));
        parameterAnnotation.addElement(new JAnnotationElement("targetNamespace",
                                                                     parameter.getTargetNamespace()));
    }
View Full Code Here

Examples of org.apache.cxf.tools.common.model.JAnnotation

                } else {
                    processor.processMethod(jm, bop.getOperationInfo());
                }

                if (headerType == this.resultHeader) {
                    JAnnotation resultAnno = jm.getAnnotationMap().get("WebResult");
                    if (resultAnno != null) {
                        resultAnno.addElement(new JAnnotationElement("header", true, true));
                    }
                }
                processParameter(jm, bop);
            }
        }
View Full Code Here

Examples of org.apache.cxf.tools.common.model.JAnnotation

        }
    }

    private void setParameterAsHeader(JavaParameter parameter) {
        parameter.setHeader(true);
        JAnnotation parameterAnnotation = parameter.getAnnotation("WebParam");
        parameterAnnotation.addElement(new JAnnotationElement("header", true, true));
        parameterAnnotation.addElement(new JAnnotationElement("name",
                                                                     parameter.getQName().getLocalPart()));
        parameterAnnotation.addElement(new JAnnotationElement("targetNamespace",
                                                                     parameter.getTargetNamespace()));
    }
View Full Code Here

Examples of org.apache.cxf.tools.common.model.JAnnotation

                    processor.processMethod(jm, bop.getOperationInfo(), jaxwsBinding);

                }

                if (headerType == this.resultHeader) {
                    JAnnotation resultAnno = jm.getAnnotationMap().get("WebResult");
                    if (resultAnno != null) {
                        resultAnno.addElement(new JAnnotationElement("header", true, true));
                    }
                }
                processParameter(jm, bop);
            }
        }
View Full Code Here

Examples of org.apache.cxf.tools.common.model.JAnnotation

        }
    }

    private void setParameterAsHeader(JavaParameter parameter) {
        parameter.setHeader(true);
        JAnnotation parameterAnnotation = parameter.getAnnotation();
        parameterAnnotation.addElement(new JAnnotationElement("header", true, true));
        parameterAnnotation.addElement(new JAnnotationElement("name",
                                                                     parameter.getQName().getLocalPart()));
        parameterAnnotation.addElement(new JAnnotationElement("targetNamespace",
                                                                     parameter.getTargetNamespace()));
    }
View Full Code Here

Examples of org.apache.cxf.tools.common.model.JAnnotation

        asyncHandler.setClassName(getAsyncClassName(method, "AsyncHandler"));
        asyncHandler.setStyle(JavaType.Style.IN);
       
        callbackMethod.addParameter(asyncHandler);
       
        JAnnotation asyncHandlerAnnotation = new JAnnotation(WebParam.class);
        asyncHandlerAnnotation.addElement(new JAnnotationElement("name", "asyncHandler"));
        asyncHandlerAnnotation.addElement(new JAnnotationElement("targetNamespace", ""));
        asyncHandler.setAnnotation(asyncHandlerAnnotation);               

        method.getInterface().addMethod(callbackMethod);
    }
View Full Code Here

Examples of org.apache.cxf.tools.common.model.JAnnotation

                        p2.setName(param.getName());
                        p2.setClassName(param.getHolderName());
                        p2.setStyle(JavaType.Style.IN);
                        callbackMethod.addParameter(p2);
                        for (String s : param.getAnnotationTags()) {
                            JAnnotation ann = param.getAnnotation(s);
                            p2.addAnnotation(s, ann);
                        }
                    } else if (!param.isHeader() && asyncCname == null) {
                        asyncCname = param.getClassName();
                    }
                } else {
                    callbackMethod.addParameter(param);
                }
            } else {
                callbackMethod.addParameter(param);
            }
        }
        JavaParameter asyncHandler = new JavaParameter();
       
        asyncHandler.setName("asyncHandler");
        asyncHandler.setCallback(true);
        asyncHandler.setClassName(getAsyncClassName(method,
                                                    "AsyncHandler",
                                                    asyncCname));
        asyncHandler.setStyle(JavaType.Style.IN);
       
        callbackMethod.addParameter(asyncHandler);
       
        JAnnotation asyncHandlerAnnotation = new JAnnotation(WebParam.class);
        asyncHandlerAnnotation.addElement(new JAnnotationElement("name", "asyncHandler"));
        asyncHandlerAnnotation.addElement(new JAnnotationElement("targetNamespace", ""));
        asyncHandler.addAnnotation("WebParam", asyncHandlerAnnotation);               

        method.getInterface().addImport("javax.jws.WebParam");
        method.getInterface().addMethod(callbackMethod);
    }
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.