Examples of javaDoc()


Examples of com.sun.codemodel.JMethod.javadoc()

        int mods = method.mods().getValue();
        mtype = mtype.unboxify();
        method = dc.method(mods, method.type(), setterName);
       
        method.javadoc().append(doc);
        method.param(mtype, "value");

        JFieldRef fr = JExpr.ref(fieldName);
        method.body().assign(fr, JExpr.ref("value"));
       
View Full Code Here

Examples of com.sun.codemodel.JMethod.javadoc()

        final JInvocation invoke = delegateImpl.staticInvoke("valueOf");
        invoke.arg(JExpr._this());
        invoke.arg(toStringDelegateStyleParam);
        toStringMethod.body()._return(invoke);
       
        JDocComment doc = toStringMethod.javadoc();
        doc.add("Generates a String representation of the contents of this type.");
        doc.add("\nThis is an extension method, produced by the 'ts' xjc plugin");
        toStringMethod.annotate(Override.class);
    }
}
View Full Code Here

Examples of com.sun.codemodel.JMethod.javadoc()

    // latitude = coordinateClass.field(JMod.PRIVATE, cm.DOUBLE, "latitud33e", JExpr.lit(0.0d));
    // altitude = coordinateClass.field(JMod.PRIVATE, cm.DOUBLE, "altitud33e", JExpr.lit(0.0d));

    final JMethod noArgConstructor = coordinateClass.constructor(JMod.PRIVATE);
    noArgConstructor.annotate(Deprecated.class);
    noArgConstructor.javadoc().add("Default no-arg constructor is private. Use overloaded constructor instead! ");
    noArgConstructor.javadoc().add("(Temporary solution, till a better and more suitable ObjectFactory is created.) ");

    final JMethod twoDoubleArgConstructor = coordinateClass.constructor(JMod.PUBLIC);
    addConstructorParam(twoDoubleArgConstructor, longitude);
    addConstructorParam(twoDoubleArgConstructor, latitude);
View Full Code Here

Examples of com.sun.codemodel.JMethod.javadoc()

    // altitude = coordinateClass.field(JMod.PRIVATE, cm.DOUBLE, "altitud33e", JExpr.lit(0.0d));

    final JMethod noArgConstructor = coordinateClass.constructor(JMod.PRIVATE);
    noArgConstructor.annotate(Deprecated.class);
    noArgConstructor.javadoc().add("Default no-arg constructor is private. Use overloaded constructor instead! ");
    noArgConstructor.javadoc().add("(Temporary solution, till a better and more suitable ObjectFactory is created.) ");

    final JMethod twoDoubleArgConstructor = coordinateClass.constructor(JMod.PUBLIC);
    addConstructorParam(twoDoubleArgConstructor, longitude);
    addConstructorParam(twoDoubleArgConstructor, latitude);
View Full Code Here

Examples of com.sun.codemodel.JMethod.javadoc()

      createArgFactoryMethod(cc, coordinateCreateMethods, sigType, methodName);
     
      coordinateCreateMethods.clear();
     
      final JMethod m = objectFactory.method(JMod.PUBLIC | JMod.STATIC, sigType, "create" + methodName);
      m.javadoc().append("Create an instance of ").append(cc.ref);
      final JInvocation returntype = JExpr._new(cc.implRef);
      final JVar arg = m.param(JMod.FINAL, String.class, "coordinates");
      m.javadoc().addParam(arg).append("required parameter");
      returntype.arg(arg);
      m.body()._return(returntype);
View Full Code Here

Examples of com.sun.codemodel.JMethod.javadoc()

     
      final JMethod m = objectFactory.method(JMod.PUBLIC | JMod.STATIC, sigType, "create" + methodName);
      m.javadoc().append("Create an instance of ").append(cc.ref);
      final JInvocation returntype = JExpr._new(cc.implRef);
      final JVar arg = m.param(JMod.FINAL, String.class, "coordinates");
      m.javadoc().addParam(arg).append("required parameter");
      returntype.arg(arg);
      m.body()._return(returntype);
      return;
    }
   
View Full Code Here

Examples of com.sun.codemodel.JMethod.javadoc()

    // Create the default, no-arg constructor
    final JMethod defaultConstructor = classOutline.implClass.constructor(mods);
    if (mods == JMod.PRIVATE) {
    defaultConstructor.annotate(Deprecated.class);
    }
    defaultConstructor.javadoc().add("Default no-arg constructor is private. Use overloaded constructor instead! ");
    defaultConstructor.javadoc().add("(Temporary solution, till a better and more suitable ObjectFactory is created.) ");
    defaultConstructor.body().invoke("super");
  }

  private void createArgConstructor(final ClassOutlineImpl cc, final Collection<JFieldVar> required) {
View Full Code Here

Examples of com.sun.codemodel.JMethod.javadoc()

    // public static final SIGTYPE createFoo() {
    // return new FooImpl();
    // }
    final JMethod m = objectFactory.method(JMod.PUBLIC | JMod.STATIC, sigType, "create" + methodName);
    m.body()._return(JExpr._new(cc.implRef));
    m.javadoc().append("Create an instance of ").append(cc.ref);
  }

  private void createArgFactoryMethod(final ClassOutlineImpl cc, final Collection<JFieldVar> required, final JClass sigType, final String methodName) {
    final JMethod m = objectFactory.method(JMod.PUBLIC | JMod.STATIC, sigType, "create" + methodName);
    final Map<String, FieldOutline> fieldOutlineasMap = Util.getRequiredFieldsAsMap(cc);
View Full Code Here

Examples of com.sun.codemodel.JMethod.javadoc()

    final JMethod defaultConstructor = classOutline.implClass.constructor(mods);
    if (mods == JMod.PRIVATE) {
    defaultConstructor.annotate(Deprecated.class);
    }
    defaultConstructor.javadoc().add("Default no-arg constructor is private. Use overloaded constructor instead! ");
    defaultConstructor.javadoc().add("(Temporary solution, till a better and more suitable ObjectFactory is created.) ");
    defaultConstructor.body().invoke("super");
  }

  private void createArgConstructor(final ClassOutlineImpl cc, final Collection<JFieldVar> required) {
    final StringBuffer debugOut = new StringBuffer();
View Full Code Here

Examples of com.sun.codemodel.JMethod.javadoc()

  }

  private void createArgFactoryMethod(final ClassOutlineImpl cc, final Collection<JFieldVar> required, final JClass sigType, final String methodName) {
    final JMethod m = objectFactory.method(JMod.PUBLIC | JMod.STATIC, sigType, "create" + methodName);
    final Map<String, FieldOutline> fieldOutlineasMap = Util.getRequiredFieldsAsMap(cc);
    m.javadoc().append("Create an instance of ").append(cc.ref);
    final JInvocation returntype = JExpr._new(cc.implRef);
    for (final JFieldVar field : required) {

      final JVar arg = m.param(JMod.FINAL, field.type(), field.name());
      m.javadoc().addParam(arg).append("required parameter");
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.