Interface IJavaDefinition

All Superinterfaces:
IJavaElement, IJavaExpression, IJavaLeftExpression, IJavaStatement

@Ser public interface IJavaDefinition extends IJavaStatement, IJavaLeftExpression
Java AST interface to represent a definition statement.

Example:

 int x = 123;
 
See Also:
  • Method Details

    • getType

      IJavaType getType()
      Get the identifier type.
      Returns:
      the identifier type
    • getCoordinates

      IdentifierCoordinates getCoordinates()
      Retrieve the coordinates specifying where the location of the identifier definition. Those coordinates are used by underlying code units to perform actions on identifiers, such as renaming.
      Returns:
      the coordinates of this definition
    • getIdentifier

      IJavaIdentifier getIdentifier()
      Get the identifier being defined.
      Returns:
      the identifier, never null
    • duplicate

      IJavaDefinition duplicate()
      Description copied from interface: IJavaElement
      Duplicate this element.
      Specified by:
      duplicate in interface IJavaElement
      Specified by:
      duplicate in interface IJavaExpression
      Specified by:
      duplicate in interface IJavaLeftExpression
      Specified by:
      duplicate in interface IJavaStatement
      Returns:
      a (possibly) duplicated object of the same type