Skip to content

Method Entity

Method Declaration Entity Entity

Method declaration entity represents a method declaration in the source code. It contains information about the method name, visibility, return type, and other attributes.

@annotation
<visibility> <returntype> <name>(<parameter>) throws <exception> {
...
return <returnvalue>;
...
throw <exception>;
...
}

Attributes

EntityDescription
getName()Method’s name
getVisibility()Method’s visibility (public, private, protected)
getReturnType()Method’s return type
getAnnotation()Method’s annotation
getArgumentType()Method’s parameter type
getArgumentName()Method’s parameter name
getThrowsType()Method’s thrown exceptions