Class CIMClassProperty<E>
java.lang.Object
javax.cim.CIMElement
javax.cim.CIMTypedElement
javax.cim.CIMValuedElement<E>
javax.cim.CIMProperty<E>
javax.cim.CIMClassProperty<E>
- Type Parameters:
E- Type parameter.
- All Implemented Interfaces:
Serializable, Comparable<CIMElement>, CIMQualifiedElementInterface
-
Constructor Summary
ConstructorsConstructorDescriptionCIMClassProperty(String pName, CIMDataType pType, E pValue, CIMQualifier<?>[] pQualifiers, boolean pKey, boolean pPropagated, String pOriginClass) This method constructs an instance ofCIMClassProperty. -
Method Summary
Modifier and TypeMethodDescriptionbooleanCompares this object against the specified object.filter(boolean pIncludeQualifiers, boolean pIncludeClassOrigin) Returns aCIMClassPropertyfiltered as specified.filter(boolean pIncludeQualifiers, boolean pIncludeClassOrigin, boolean pLocalOnly) Returns aCIMClassPropertyfiltered as specified.CIMQualifier<?> getQualifier(int pIndex) Get a qualifier by index.CIMQualifier<?> getQualifier(String pName) Gets a qualifier by name.intGet the number of qualifiers defined for this property.CIMQualifier<?>[]Returns the list of qualifiers for this property.getQualifierValue(String pName) Gets a qualifier value by name.booleanhasQualifier(String pName) Checks whether the specified qualifier is one of the qualifiers defined for this property.booleanhasQualifierValue(String pName, Object pValue) Checks whether the specified qualifier is one of the qualifiers defined for this property with the specified value.Methods inherited from class CIMProperty
getOriginClass, isKey, isPropagatedMethods inherited from class CIMValuedElement
getValue, hashCode, toStringMethods inherited from class CIMTypedElement
getDataTypeMethods inherited from class CIMElement
compareTo, getName
-
Constructor Details
-
CIMClassProperty
public CIMClassProperty(String pName, CIMDataType pType, E pValue, CIMQualifier<?>[] pQualifiers, boolean pKey, boolean pPropagated, String pOriginClass) This method constructs an instance ofCIMClassProperty.- Parameters:
pName- The name of the property.pType- The data type of the property.pValue- The value of the property.pQualifiers- The qualifiers for the property.pKey-trueif the property is a key, otherwisefalse.pPropagated-trueif the property was inherited, otherwisefalse.pOriginClass- The original class in which the property was defined.
-
-
Method Details
-
equals
Compares this object against the specified object. The result istrueif and only if the argument is not null and is aCIMClassPropertythat represents the same name, type and value as this object.- Overrides:
equalsin classCIMProperty<E>- Parameters:
pObj- The object to compare with.- Returns:
trueif the objects are the same;falseotherwise.
-
filter
Returns aCIMClassPropertyfiltered as specified.- Parameters:
pIncludeQualifiers- Iftrueall qualifiers are returned; otherwise no qualifiers.pIncludeClassOrigin- Iftruethe class origin is included; otherwise no class origin is present.- Returns:
- A filtered
CIMClassProperty.
-
filter
public CIMClassProperty<E> filter(boolean pIncludeQualifiers, boolean pIncludeClassOrigin, boolean pLocalOnly) Returns aCIMClassPropertyfiltered as specified.- Parameters:
pIncludeQualifiers- Iftrueall qualifiers are returned; otherwise no qualifiers.pIncludeClassOrigin- Iftruethe class origin is included; otherwise no class origin is present.pLocalOnly- Iftrueonly the qualifiers that were not propagated will be included.- Returns:
- CIMClassProperty A filtered
CIMClassProperty.
-
getQualifier
Get a qualifier by index.- Specified by:
getQualifierin interfaceCIMQualifiedElementInterface- Parameters:
pIndex- The index of the qualifier to retrieve.- Returns:
- The qualifier at the specified index.
- Throws:
ArrayIndexOutOfBoundsException
-
getQualifier
Gets a qualifier by name.- Specified by:
getQualifierin interfaceCIMQualifiedElementInterface- Parameters:
pName- The name of the qualifier to get.- Returns:
- The qualifier requested or
nullif the qualifier does not exist.
-
getQualifierCount
public int getQualifierCount()Get the number of qualifiers defined for this property.- Specified by:
getQualifierCountin interfaceCIMQualifiedElementInterface- Returns:
- The number of qualifiers defined for this property.
-
getQualifiers
Returns the list of qualifiers for this property.- Specified by:
getQualifiersin interfaceCIMQualifiedElementInterface- Returns:
- Qualifiers for this property.
-
getQualifierValue
Gets a qualifier value by name.- Specified by:
getQualifierValuein interfaceCIMQualifiedElementInterface- Parameters:
pName- The name of the qualifier to get.- Returns:
nullif the qualifier does not exist or value isnull, otherwise returns the reference to the qualifier.
-
hasQualifier
Checks whether the specified qualifier is one of the qualifiers defined for this property.- Specified by:
hasQualifierin interfaceCIMQualifiedElementInterface- Parameters:
pName- The name of the qualifier.- Returns:
trueif the qualifier exists in this property, otherwisefalse.
-
hasQualifierValue
Checks whether the specified qualifier is one of the qualifiers defined for this property with the specified value. This method will returnfalseif the qualifier is not applied or if the value does not match.- Specified by:
hasQualifierValuein interfaceCIMQualifiedElementInterface- Parameters:
pName- The name of the qualifier.pValue- The value to be tested.- Returns:
trueif the qualifier exists in this property, otherwisefalse.
-