public class MethodImp extends Object implements IMethodReader, IMethodWriter, Comparable<MethodImp>, Cloneable
| Constructor and Description |
|---|
MethodImp(IMethodReader method)
Constructor to receive the method.
|
MethodImp(String name)
Constructor to receive the name of the method.
|
| Modifier and Type | Method and Description |
|---|---|
IAnnotationPropertyWriter |
annotation(Class<? extends Annotation> annotation)
Add an annotation to this.
|
IAnnotationPropertyWriter |
annotation(Class<? extends Annotation> annotation,
LocationEnum location)
Add an annotation and defining the location of it.
|
IAnnotationPropertyWriter |
annotation(IAnnotationReader annotation)
Add a annotation wrapper to this.
|
Collection<IAnnotationReader> |
annotations()
Inform the annotations that you want in your method.
|
Object |
clone() |
int |
compareTo(MethodImp other) |
boolean |
equals(Object obj) |
Collection<Class<?>> |
exceptions()
Inform the exceptions that you want in your method to throw.
|
IMethodWriter |
exceptions(Class<?>... exceptions)
Define the exceptions that you want in your method throw.
|
int |
hashCode() |
Collection<ModifierEnum> |
modifiers()
Inform the modifiers that you want in your method.
|
IMethodWriter |
modifiers(ModifierEnum... modifiers)
Define the modifiers that you want in your method.
|
String |
name()
Inform the name of your method.
|
IMethodWriter |
name(String name)
Define the name of your method.
|
IFieldWriter |
parameter(String name,
Class<?> type)
Define the parameters that you want in your method.
|
Collection<IFieldReader> |
parameters()
Inform the parameters that you want in your method.
|
Class<?> |
returnType()
Inform the class type returned of your method.
|
IMethodWriter |
returnType(Class<?> clazz)
Define the class type returned of your method.
|
IMethodWriter |
returnTypeAsVoid()
Define the class type name of your method as void.
|
String |
toString() |
Object |
value()
Inform the default value to your method.
|
IMethodWriter |
value(Object value)
Define the default value that you want in your method.
|
VisibilityEnum |
visibility()
Inform the visibility of your method.
|
IMethodWriter |
visibility(VisibilityEnum visibility)
Define the visibility for your method.
|
public MethodImp(String name)
name - of the methodpublic MethodImp(IMethodReader method)
method - to be addedpublic Object clone() throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedExceptionpublic IMethodWriter name(String name)
IMethodWritername in interface IMethodWritername - of the methodpublic IMethodWriter returnTypeAsVoid()
IMethodWriterreturnTypeAsVoid in interface IMethodWriterpublic IMethodWriter returnType(Class<?> clazz)
IMethodWriterreturnType in interface IMethodWriterclazz - of the returned type of the methodpublic IFieldWriter parameter(String name, Class<?> type)
IMethodWriterparameter in interface IMethodWritername - of the parametertype - of the parameterpublic String name()
IMethodReadername in interface IMethodReaderpublic Class<?> returnType()
IMethodReaderreturnType in interface IMethodReaderpublic Collection<IFieldReader> parameters()
IMethodReaderparameters in interface IMethodReaderpublic IMethodWriter modifiers(ModifierEnum... modifiers)
IMethodWriterEx: FINAL, ABSTRACT...
modifiers in interface IMethodWritermodifiers - to the methodpublic Collection<ModifierEnum> modifiers()
IMethodReadermodifiers in interface IMethodReaderpublic IMethodWriter visibility(VisibilityEnum visibility)
IMethodWriterEx: PUBLIC, PRIVATE or PROTECTED
visibility in interface IMethodWritervisibility - of the methodpublic VisibilityEnum visibility()
IMethodReadervisibility in interface IMethodReaderpublic IAnnotationPropertyWriter annotation(Class<? extends Annotation> annotation)
IAnnotationWriterannotation in interface IAnnotationWriterannotation - to associatepublic IAnnotationPropertyWriter annotation(Class<? extends Annotation> annotation, LocationEnum location)
IAnnotationWriterannotation in interface IAnnotationWriterannotation - to associatelocation - to bepublic IAnnotationPropertyWriter annotation(IAnnotationReader annotation)
IAnnotationWriterannotation in interface IAnnotationWriterannotation - to associatepublic Collection<IAnnotationReader> annotations()
IMethodReaderannotations in interface IMethodReaderpublic IMethodWriter exceptions(Class<?>... exceptions)
IMethodWriterexceptions in interface IMethodWriterexceptions - of the methodpublic Collection<Class<?>> exceptions()
IMethodReaderexceptions in interface IMethodReaderpublic IMethodWriter value(Object value)
IMethodWriterONLY USED FOR ANNOTATION !!!!
value in interface IMethodWritervalue - to be default (annotations only)public Object value()
IMethodReaderONLY USED FOR ANNOTATION !!!!
value in interface IMethodReaderpublic int compareTo(MethodImp other)
compareTo in interface Comparable<MethodImp>Copyright © 2018 Esfinge Framework. All rights reserved.