Enum Class SearchContext

java.lang.Object
java.lang.Enum<SearchContext>
net.ssehub.easy.varModel.model.search.SearchContext
All Implemented Interfaces:
Serializable, Comparable<SearchContext>, Constable

public enum SearchContext extends Enum<SearchContext>
Defines some search contexts, i.e. to hint the search whether local variables shall be included.
Author:
Holger Eichelberger
  • Enum Constant Details

    • ALL

      public static final SearchContext ALL
      Include all element types.
    • ID

      public static final SearchContext ID
      Search for only, i.e. unqualified names.
    • QUALIFIED_NAME

      public static final SearchContext QUALIFIED_NAME
      Search for qualified names.
    • PROJECT

      public static final SearchContext PROJECT
      Search on project level.
    • COMPOUND

      public static final SearchContext COMPOUND
      Search within compound level.
    • CONSTRAINT

      public static final SearchContext CONSTRAINT
      Search within a constraint.
    • OPERATION_DEFINITION

      public static final SearchContext OPERATION_DEFINITION
      Search within an operation definition.
    • FREEZE

      public static final SearchContext FREEZE
      Search within a freeze.
    • EVAL

      public static final SearchContext EVAL
      Search within an eval.
    • LET

      public static final SearchContext LET
      Search within a let expression.
  • Field Details

    • includeQualifiedNames

      private boolean includeQualifiedNames
    • includeUnqualifiedNames

      private boolean includeUnqualifiedNames
    • includeVariableDeclarations

      private boolean includeVariableDeclarations
    • includeOperations

      private boolean includeOperations
    • includeOperationDefinitions

      private boolean includeOperationDefinitions
    • includeConstraints

      private boolean includeConstraints
    • includeEvals

      private boolean includeEvals
    • includeLets

      private boolean includeLets
  • Constructor Details

    • SearchContext

      private SearchContext(String spec)
      Creates a new search context. We use a string here as parameter as we otherwise would have more than 5 parameters in total.
      Parameters:
      spec - the specification of included elements, "q" stands for qualified names, "u" stands for unqualified names, "v" for variable declarations, "o" for operations, "O" for operation definitions, "c" for constraints, "e" for evals, "l" for lets
  • Method Details

    • values

      public static SearchContext[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static SearchContext valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • includeQualifiedNames

      public boolean includeQualifiedNames()
      Returns whether qualified names shall be included.
      Returns:
      true if they shall be included, false else
    • includeUnqualifiedNames

      public boolean includeUnqualifiedNames()
      Returns whether unqualified names shall be included.
      Returns:
      true if they shall be included, false else
    • includeVariableDeclarations

      public boolean includeVariableDeclarations()
      Returns whether variable declarations shall be included per se.
      Returns:
      true if they shall be included, false else
    • includeOperations

      public boolean includeOperations()
      Returns whether available operations shall be included.
      Returns:
      true if they shall be included, false else
    • includeOperationDefinitions

      public boolean includeOperationDefinitions()
      Returns whether operation definitions shall be included.
      Returns:
      true if they shall be included, false else
    • includeConstraints

      public boolean includeConstraints()
      Returns whether constraints shall be included.
      Returns:
      true if they shall be included, false else
    • includeEvals

      public boolean includeEvals()
      Returns whether evals shall be included.
      Returns:
      true if they shall be included, false else
    • includeLets

      public boolean includeLets()
      Returns whether lets shall be included.
      Returns:
      true if they shall be included, false else