Class JavaEnumId

    • Constructor Detail

      • JavaEnumId

        public JavaEnumId​(JavaId _declaration_ctx,
                          String _simple_name)
        Constructor for creating the identifier of an enum.
        Parameters:
        _declaration_ctx - a JavaId object.
        _simple_name - a String object.
    • Method Detail

      • isNested

        public boolean isNested()
        Returns true if the enum is not directly declared within a package, but within another construct like a class or interface.
        Returns:
        a boolean.
      • getQualifiedName

        public String getQualifiedName()
        Returns the fully qualified class name, i.e., including the name of the package in which the class is defined.
        Specified by:
        getQualifiedName in class ConstructId
      • getName

        public String getName()
        Returns a class name that is unique within the package in which the class is defined. In case of nested classes, the names of parent classes will be included (e.g., OuterClass$InnerClass).
        Specified by:
        getName in class ConstructId
      • getSimpleName

        public String getSimpleName()
        Returns the class name without considering any context.
        Specified by:
        getSimpleName in class ConstructId
      • getDefinitionContext

        public ConstructId getDefinitionContext()

        getDefinitionContext.

        Returns the name of the Java package in which the class or nested class is defined. Returns null if a class is defined outside of a package.
        Specified by:
        getDefinitionContext in class JavaId
        Returns:
        a ConstructId object.
      • getJavaPackageId

        public JavaPackageId getJavaPackageId()
        Returns the Java package in the context of which the construct is defined. Returns the Java package in the context of which the construct is defined.
        Specified by:
        getJavaPackageId in class JavaId
        Returns:
        a JavaPackageId object.