Interface ISymbol

All Known Subinterfaces:
IScopeSpanningSymbol, IStereotypeSymbol
All Known Implementing Classes:
SymbolWithScopeOfUnknownKind

public interface ISymbol
  • Method Details

    • getName

      String getName()
      Returns:
      the symbol name
    • getPackageName

      String getPackageName()
      Returns:
      the package of this symbol. The package name of all symbols within an artifact is usually the same. For example, the package name of a state chart p.q.SC and its containing state s are the same, i.e., p.q.
      See Also:
    • getFullName

      String getFullName()
      Returns:
      the package of this symbol. All symbols within an artifact usually have the same package name. For example, the state chart p.q.SC and its containing states all have the package p.q.
      See Also:
    • getEnclosingScope

      IScope getEnclosingScope()
      Returns:
      Returns the enclosing scope of this symbol. Symbol classes implementing the ISymbol interface override this method and refine the return type to the scASTope classes of the language.
    • getAccessModifier

      default AccessModifier getAccessModifier()
      Returns:
      the access modifier, such as public or protected in Java. By default, the AccessModifier.ALL_INCLUSION is returned, which indicates that the symbol does not have any access modifier. Note that this is not the same as the (implicit) access modifier BasicAccessModifier.PACKAGE_LOCAL of Java.
    • setAccessModifier

      void setAccessModifier(AccessModifier accessModifier)
      Sets the access modifier, such as public or protected in Java.
      Parameters:
      accessModifier - the access modifier
    • getStereoinfo

      Returns the stereotypes of this symbol, associated with values for them if present.
      The keys of the map reference IStereotypeSymbols, while the values reference the optionally associated stereovalue.
    • isPresentAstNode

      boolean isPresentAstNode()
    • getAstNode

      ASTNode getAstNode()
    • getSourcePosition

      default de.se_rwth.commons.SourcePosition getSourcePosition()
      Returns:
      the position of this symbol in the source model. By default, it is the source position of the ast node.
    • sortSymbolsByPosition

      static <T extends ISymbol> List<T> sortSymbolsByPosition(Collection<T> unorderedSymbols)
    • accept

      default void accept(ITraverser visitor)