public class BuildMetaConstructor extends MetaConstructor implements Builder
Constructor and Description |
---|
BuildMetaConstructor(BuildMetaClass declaringClass) |
BuildMetaConstructor(BuildMetaClass declaringClass,
Statement body) |
BuildMetaConstructor(BuildMetaClass declaringClass,
Statement body,
DefParameters defParameters) |
BuildMetaConstructor(BuildMetaClass declaringClass,
Statement body,
Scope scope,
DefParameters defParameters) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
Annotation[] |
getAnnotations() |
Statement |
getBody() |
MetaClass[] |
getCheckedExceptions() |
MetaClass |
getDeclaringClass() |
String |
getDeclaringClassName() |
MetaType[] |
getGenericParameterTypes() |
MetaType |
getGenericReturnType()
Returns the MetaType representing the return type of the method.
|
String |
getName() |
MetaParameter[] |
getParameters() |
MetaConstructor |
getReifiedFormOf() |
MetaClass |
getReturnType()
Returns the MetaClass representing this method's return type.
|
MetaTypeVariable[] |
getTypeParameters()
Returns the array of type variables declared on this generic declaration
site, in the order they were declared in the source code.
|
boolean |
isAbstract() |
boolean |
isFinal() |
boolean |
isPrivate() |
boolean |
isProtected() |
boolean |
isPublic() |
boolean |
isReifiedForm() |
boolean |
isStatic() |
boolean |
isSynchronized() |
boolean |
isSynthetic() |
boolean |
isTransient() |
boolean |
isVarArgs() |
boolean |
isVolatile() |
void |
setBody(Statement body) |
void |
setConstructorComment(String constructorComment) |
void |
setDefParameters(DefParameters defParameters) |
void |
setReifiedFormOf(MetaConstructor reifiedFormOf) |
void |
setScope(Scope scope) |
String |
toJavaString()
Validates the statement and generates the String representation.
|
asConstructor
asMethod, getAnnotation, getParametersAnnotatedWith, hashCode, hashString, toString
isAnnotationPresent
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getAnnotation, isAnnotationPresent
public BuildMetaConstructor(BuildMetaClass declaringClass)
public BuildMetaConstructor(BuildMetaClass declaringClass, Statement body)
public BuildMetaConstructor(BuildMetaClass declaringClass, Statement body, DefParameters defParameters)
public BuildMetaConstructor(BuildMetaClass declaringClass, Statement body, Scope scope, DefParameters defParameters)
public MetaParameter[] getParameters()
getParameters
in class MetaConstructor
public MetaType[] getGenericParameterTypes()
getGenericParameterTypes
in class MetaConstructor
public boolean isVarArgs()
isVarArgs
in class MetaConstructor
public MetaClass getDeclaringClass()
getDeclaringClass
in interface MetaClassMember
public String getDeclaringClassName()
getDeclaringClassName
in interface MetaClassMember
public boolean isAbstract()
isAbstract
in interface MetaClassMember
public boolean isPublic()
isPublic
in interface MetaClassMember
public boolean isPrivate()
isPrivate
in interface MetaClassMember
public boolean isProtected()
isProtected
in interface MetaClassMember
public boolean isFinal()
isFinal
in interface MetaClassMember
public boolean isStatic()
isStatic
in interface MetaClassMember
public boolean isTransient()
isTransient
in interface MetaClassMember
public boolean isSynthetic()
isSynthetic
in interface MetaClassMember
public boolean isVolatile()
isVolatile
in interface MetaClassMember
public boolean isSynchronized()
isSynchronized
in interface MetaClassMember
public void setScope(Scope scope)
public Annotation[] getAnnotations()
getAnnotations
in interface HasAnnotations
public MetaTypeVariable[] getTypeParameters()
MetaGenericDeclaration
getTypeParameters
in interface MetaGenericDeclaration
public Statement getBody()
public void setBody(Statement body)
public void setDefParameters(DefParameters defParameters)
public MetaClass[] getCheckedExceptions()
getCheckedExceptions
in class MetaMethod
public String getName()
getName
in interface MetaClassMember
getName
in class MetaMethod
public MetaClass getReturnType()
MetaMethod
getReturnType
in class MetaMethod
public MetaType getGenericReturnType()
MetaMethod
MetaClass
equivalent to the one returned by
MetaMethod.getReturnType()
. Other possible types could be
MetaWildcardType
, MetaParameterizedType
, and
MetaTypeVariable
.
As of Errai 2.2, some implementations of this method are incomplete and will return null if they cannot make sense of the method's return type.
getGenericReturnType
in class MetaMethod
public boolean isReifiedForm()
public MetaConstructor getReifiedFormOf()
public void setReifiedFormOf(MetaConstructor reifiedFormOf)
public void setConstructorComment(String constructorComment)
public String toJavaString()
Builder
toJavaString
in interface Builder
public boolean equals(Object o)
equals
in class MetaMethod
Copyright © 2013-2015 JBoss, a division of Red Hat. All Rights Reserved.