Amplication AST Libraries Documentation
    Preparing search index...

    Interface defining the arguments required to create a new Method instance.

    Args

    interface Args {
        name: string;
        access: Access;
        parameters?: Parameter[];
        returnType?: Type;
        body?: CodeBlock;
        annotations?: Annotation[];
        javadoc?: string;
        type?: MethodType;
        static_?: boolean;
        abstract_?: boolean;
        classReference?: ClassReference;
        final_?: boolean;
        synchronized_?: boolean;
        throws?: ClassReference[];
        typeParameters?: string[];
    }
    Index

    Properties

    name: string

    The name of the Java method

    access: Access

    The access level of the method (public, private, protected)

    parameters?: Parameter[]

    The parameters of the method

    returnType?: Type

    The return type of the method

    body?: CodeBlock

    The body of the method containing the implementation

    annotations?: Annotation[]

    Method annotations like @Override, @GetMapping, etc.

    javadoc?: string

    Documentation/JavaDoc for the method

    type?: MethodType

    The type of the method (instance, static, abstract, default)

    static_?: boolean

    Whether this method is static

    abstract_?: boolean

    Whether this method is abstract

    classReference?: ClassReference

    The class this method belongs to, if any

    final_?: boolean

    Whether this method is final

    synchronized_?: boolean

    Whether this method is synchronized

    throws?: ClassReference[]

    Exceptions thrown by this method

    typeParameters?: string[]

    Generic type parameters for this method