@Internal public class JavaMethodElement extends AbstractJavaElement implements MethodElement
ExecutableElement
.EMPTY_ELEMENT_ARRAY
CLASS_NAME_SUFFIX, EMPTY_METADATA, VALUE_MEMBER
EMPTY
Constructor and Description |
---|
JavaMethodElement(JavaClassElement declaringClass,
javax.lang.model.element.ExecutableElement executableElement,
AnnotationMetadata annotationMetadata,
JavaVisitorContext visitorContext) |
Modifier and Type | Method and Description |
---|---|
ClassElement |
getDeclaringType() |
java.util.Optional<java.lang.String> |
getDocumentation() |
ClassElement |
getGenericReturnType()
The generic return type of the method.
|
ClassElement |
getOwningType()
The owing type is the type that owns this element.
|
ParameterElement[] |
getParameters() |
ClassElement |
getReturnType() |
annotate, getAnnotationMetadata, getName, getNativeType, isAbstract, isFinal, isPrivate, isProtected, isPublic, isStatic, mirrorToClassElement, mirrorToClassElement, parameterizedClassElement, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
annotate, annotate, annotate, annotate, getName, getNativeType, getSimpleName, isAbstract, isFinal, isPrivate, isProtected, isPublic, isStatic
booleanValue, booleanValue, booleanValue, booleanValue, classValue, classValue, classValue, classValue, classValues, classValues, classValues, classValues, doubleValue, doubleValue, doubleValue, enumValue, enumValue, enumValue, enumValue, enumValues, enumValues, enumValues, enumValues, findAnnotation, findAnnotation, findDeclaredAnnotation, findDeclaredAnnotation, getAnnotation, getAnnotation, getAnnotationNameByStereotype, getAnnotationNameByStereotype, getAnnotationNames, getAnnotationNamesByStereotype, getAnnotationNamesByStereotype, getAnnotationType, getAnnotationType, getAnnotationTypeByStereotype, getAnnotationTypeByStereotype, getAnnotationTypesByStereotype, getAnnotationTypesByStereotype, getAnnotationValuesByType, getDeclaredAnnotation, getDeclaredAnnotation, getDeclaredAnnotationNameByStereotype, getDeclaredAnnotationNames, getDeclaredAnnotationNamesByStereotype, getDeclaredAnnotationTypeByStereotype, getDeclaredAnnotationTypeByStereotype, getDeclaredAnnotationValuesByType, getDefaultValue, getDefaultValue, getDefaultValue, getDefaultValue, getDefaultValues, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValues, getValues, hasAnnotation, hasAnnotation, hasDeclaredAnnotation, hasDeclaredAnnotation, hasDeclaredStereotype, hasDeclaredStereotype, hasDeclaredStereotype, hasSimpleAnnotation, hasSimpleDeclaredAnnotation, hasStereotype, hasStereotype, hasStereotype, hasStereotype, intValue, intValue, intValue, isAnnotationPresent, isDeclaredAnnotationPresent, isEmpty, isFalse, isFalse, isPresent, isPresent, isTrue, isTrue, longValue, longValue, stringValue, stringValue, stringValue, stringValue, stringValues, stringValues, synthesize, synthesizeAll, synthesizeAnnotationsByType, synthesizeDeclared, synthesizeDeclared, synthesizeDeclaredAnnotationsByType
isDeclaredNonNull, isDeclaredNullable, isNonNull, isNullable
getAnnotationMetadata
public JavaMethodElement(JavaClassElement declaringClass, javax.lang.model.element.ExecutableElement executableElement, AnnotationMetadata annotationMetadata, JavaVisitorContext visitorContext)
declaringClass
- The declaring classexecutableElement
- The ExecutableElement
annotationMetadata
- The annotation metadatavisitorContext
- The visitor context@NonNull public ClassElement getGenericReturnType()
MethodElement
getGenericReturnType
in interface MethodElement
@NonNull public ClassElement getReturnType()
getReturnType
in interface MethodElement
public java.util.Optional<java.lang.String> getDocumentation()
getDocumentation
in interface Element
public ParameterElement[] getParameters()
getParameters
in interface MethodElement
public ClassElement getDeclaringType()
getDeclaringType
in interface MemberElement
public ClassElement getOwningType()
MemberElement
MemberElement.getDeclaringType()
in the case of inheritance since this method will return the subclass that owners the inherited member,
whilst MemberElement.getDeclaringType()
will return the super class that declares the type.getOwningType
in interface MemberElement