Package com.sun.codemodel

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


    final JMethod generateUnMarshallerFile = cc.implClass.method(JMod.PUBLIC | JMod.STATIC, kmlClass, "unmarshal");
    generateUnMarshallerFile.param(JMod.FINAL, fileClass, "file");
    generateUnMarshallerFile.javadoc().add("KML to Java\n");
    generateUnMarshallerFile.javadoc().add("KML given as a file object is transformed into a graph of Java objects.\n");
    generateUnMarshallerFile.javadoc().add("Similar to the method: \n");
    generateUnMarshallerFile.javadoc().add("unmarshal(final File, final boolean) \n");
    generateUnMarshallerFile.javadoc().add("with the exception that the File object is not validated (boolean is false). ");
    generateUnMarshallerFile.javadoc().trimToSize();
    generateUnMarshallerFile.body()._return(
        kmlClass.boxify().staticInvoke(generateUnMarshallerFileFile).arg(fileunmarshallVar).arg(JExpr.FALSE));
View Full Code Here


    final JMethod generateUnMarshallerFile = cc.implClass.method(JMod.PUBLIC | JMod.STATIC, kmlClass, "unmarshal");
    generateUnMarshallerFile.param(JMod.FINAL, fileClass, "file");
    generateUnMarshallerFile.javadoc().add("KML to Java\n");
    generateUnMarshallerFile.javadoc().add("KML given as a file object is transformed into a graph of Java objects.\n");
    generateUnMarshallerFile.javadoc().add("Similar to the method: \n");
    generateUnMarshallerFile.javadoc().add("unmarshal(final File, final boolean) \n");
    generateUnMarshallerFile.javadoc().add("with the exception that the File object is not validated (boolean is false). ");
    generateUnMarshallerFile.javadoc().trimToSize();
    generateUnMarshallerFile.body()._return(
        kmlClass.boxify().staticInvoke(generateUnMarshallerFileFile).arg(fileunmarshallVar).arg(JExpr.FALSE));
  }
View Full Code Here

    generateUnMarshallerFile.param(JMod.FINAL, fileClass, "file");
    generateUnMarshallerFile.javadoc().add("KML to Java\n");
    generateUnMarshallerFile.javadoc().add("KML given as a file object is transformed into a graph of Java objects.\n");
    generateUnMarshallerFile.javadoc().add("Similar to the method: \n");
    generateUnMarshallerFile.javadoc().add("unmarshal(final File, final boolean) \n");
    generateUnMarshallerFile.javadoc().add("with the exception that the File object is not validated (boolean is false). ");
    generateUnMarshallerFile.javadoc().trimToSize();
    generateUnMarshallerFile.body()._return(
        kmlClass.boxify().staticInvoke(generateUnMarshallerFileFile).arg(fileunmarshallVar).arg(JExpr.FALSE));
  }
View Full Code Here

    generateUnMarshallerFile.javadoc().add("KML to Java\n");
    generateUnMarshallerFile.javadoc().add("KML given as a file object is transformed into a graph of Java objects.\n");
    generateUnMarshallerFile.javadoc().add("Similar to the method: \n");
    generateUnMarshallerFile.javadoc().add("unmarshal(final File, final boolean) \n");
    generateUnMarshallerFile.javadoc().add("with the exception that the File object is not validated (boolean is false). ");
    generateUnMarshallerFile.javadoc().trimToSize();
    generateUnMarshallerFile.body()._return(
        kmlClass.boxify().staticInvoke(generateUnMarshallerFileFile).arg(fileunmarshallVar).arg(JExpr.FALSE));
  }

  private JMethod generateValidateMethod(final ClassOutlineImpl cc) {
View Full Code Here

        setter.body().assign( JExpr._this().ref( field ), valueParam );

        getter.javadoc().append( "Gets the value of the " + name + " property." );
        getter.javadoc().addReturn().append( "The value of the " + name + " property." );

        setter.javadoc().append( "Sets the value of the " + name + " property." );
        setter.javadoc().addParam( valueParam ).append( "The new value of the " + name + " property." );
    }

    private void generateCollectionSetter( final JCodeModel cm, final ClassOutline c, final CPropertyInfo p )
    {
View Full Code Here

        getter.javadoc().append( "Gets the value of the " + name + " property." );
        getter.javadoc().addReturn().append( "The value of the " + name + " property." );

        setter.javadoc().append( "Sets the value of the " + name + " property." );
        setter.javadoc().addParam( valueParam ).append( "The new value of the " + name + " property." );
    }

    private void generateCollectionSetter( final JCodeModel cm, final ClassOutline c, final CPropertyInfo p )
    {
        final JFieldVar field = c.implClass.fields().get( p.getName( false ) );
View Full Code Here

        final JVar valueParam = setter.param( JMod.FINAL, field.type(), "value" );
        final JBlock body = setter.body();
        body.directStatement( "// " + getMessage( "title" ) );
        body.assign( JExpr._this().ref( field ), valueParam );

        setter.javadoc().append( "Sets the value of the " + p.getName( false ) + " property." );
        setter.javadoc().addParam( valueParam ).append( "The new value of the " + p.getName( false ) + " property." );
    }

    private void generateTemporalBasic( final FieldOutline f )
    {
View Full Code Here

        final JBlock body = setter.body();
        body.directStatement( "// " + getMessage( "title" ) );
        body.assign( JExpr._this().ref( field ), valueParam );

        setter.javadoc().append( "Sets the value of the " + p.getName( false ) + " property." );
        setter.javadoc().addParam( valueParam ).append( "The new value of the " + p.getName( false ) + " property." );
    }

    private void generateTemporalBasic( final FieldOutline f )
    {
        // Getter.
View Full Code Here

        getter.body().assign( JExpr.refthis( field.name() ), f.parent()._package().objectFactory().
            staticInvoke( "createCalendar" ).arg( JExpr.refthis( f.getPropertyInfo().getName( false ) ) ) );

        getter.body()._return( JExpr.refthis( field.name() ) );

        getter.javadoc().append(
            "Gets the value of the jpa" + f.getPropertyInfo().getName( true ) + " property." + lineSeparator );

        getter.javadoc().append(
            "<p>This method returns the value of the " + f.getPropertyInfo().getName( false ) + " property "
            + "transformed to a " + Calendar.class.getName() + " instance.</p>" + lineSeparator );
View Full Code Here

        getter.body()._return( JExpr.refthis( field.name() ) );

        getter.javadoc().append(
            "Gets the value of the jpa" + f.getPropertyInfo().getName( true ) + " property." + lineSeparator );

        getter.javadoc().append(
            "<p>This method returns the value of the " + f.getPropertyInfo().getName( false ) + " property "
            + "transformed to a " + Calendar.class.getName() + " instance.</p>" + lineSeparator );

        getter.javadoc().addReturn().append(
            "The value of the jpa" + f.getPropertyInfo().getName( true ) + " property." );
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.