Class Qualifier

java.lang.Object
net.aifusion.metamodel.Qualifier

public class Qualifier extends Object
Element to represent a CIM Qualifier. Qualifiers are immutable once constructed
Author:
Sharad Singhal
  • Method Details

    • getDataType

      public DataType getDataType()
      Get the data type of this qualifier dataValue
      Returns:
      - data type associated with this qualifier
    • getValue

      public DataValue getValue()
      Get the dataValue of this qualifier. If no dataValue was specified, the default dataValue from the qualifier type is returned
      Returns:
      - dataValue of this qualifier. Return null if no default is given. A non-null dataValue containing a null is returned if a nullvalue is declared either for the qualifer or the qualifier type.
      See Also:
    • hasValue

      public boolean hasValue()
      Check if this qualifier has a dataValue
      Returns:
      - true if this qualifier has a dataValue defined in it, false otherwise
      See Also:
    • hasNonNullValue

      public boolean hasNonNullValue()
      Check if this Qualifier has a non-null dataValue
      Returns:
      - true if this qualifier has a non-null dataValue defined in it
      See Also:
    • getQualifierType

      public QualifierType getQualifierType()
      Return the qualifier type associated with this qualifier
      Returns:
      - qualifier type associated with this qualifier
    • hasScope

      public boolean hasScope(Scope scope)
      Check if this qualifier has a given scope
      Parameters:
      scope - - scope for which this qualifier is being checked
      Returns:
      - true if this qualifier has the given scope type, else false
    • appliesTo

      public boolean appliesTo(ElementType elementType)
      Check if this qualifier applies to a given elementType
      Parameters:
      elementType - - elementType to check
      Returns:
      - true if this qualifier can be applied to the given element type, false otherwise
    • equals

      public boolean equals(Object o)
      Check if this qualifier is the same as some other qualifier. A qualifier is considered the same as some other qualifier, if it has the same qualifierType and value
      Parameters:
      o - - other qualifier
      Returns:
      - true if both qualifiers are the same, else return false
    • hashCode

      public int hashCode()
    • getName

      public String getName()
      Get the name of this element
      Returns:
      - name of this element
      See Also:
    • getLowerCaseName

      public String getLowerCaseName()
      Get the case-normalized (lower case) name for this element
      Returns:
      - name of this element normalized to lower case
      See Also:
    • getElementType

      public ElementType getElementType()
      Get the CIM type of this element
      Returns:
      - CIMType for this element
      See Also:
    • toMOF

      public String toMOF()
      Return the MOF representation of this element
      Returns:
      - String containing MOF representation of this element
    • toString

      public String toString()
      Overrides:
      toString in class Object