Package org.sblim.cimclient.internal.cim
Class CIMQualifiedElementInterfaceImpl
- java.lang.Object
-
- org.sblim.cimclient.internal.cim.CIMQualifiedElementInterfaceImpl
-
- All Implemented Interfaces:
java.io.Serializable
,CIMQualifiedElementInterface
public class CIMQualifiedElementInterfaceImpl extends java.lang.Object implements CIMQualifiedElementInterface, java.io.Serializable
Class CIMQualifiedElementInterfaceImpl is responsible for implementing the functionality of javax.cim.CIMQualifiedElementInterface- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CIMQualifiedElementInterfaceImpl(CIMQualifier<?>[] pQualifiers)
Ctor.CIMQualifiedElementInterfaceImpl(CIMQualifier<?>[] pQualifiers, boolean pIsKeyed)
Ctor.CIMQualifiedElementInterfaceImpl(CIMQualifier<?>[] pQualifiers, boolean pIsKeyed, boolean pKeepEmbObj)
Ctor.CIMQualifiedElementInterfaceImpl(CIMQualifier<?>[] pQualifiers, boolean pIsKeyed, boolean pKeepEmbObj, boolean pIsAssociation)
Ctor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object pObj)
CIMQualifier<?>
getQualifier(int pIndex)
Get a qualifier by index.CIMQualifier<?>
getQualifier(java.lang.String pName)
Gets a qualifier by name.int
getQualifierCount()
Get the number of qualifiers defined for this CIM Element.CIMQualifier<?>[]
getQualifiers()
Returns the list of qualifiers for this class.CIMQualifier<?>[]
getQualifiers(boolean pLocalOnly)
getQualifiers - helps filtering based on the propagated flag.java.lang.Object
getQualifierValue(java.lang.String pName)
Gets a qualifier value by name.int
hashCode()
boolean
hasQualifier(java.lang.String pName)
Checks whether the specified qualifier is one of the qualifiers in this CIM element.boolean
hasQualifierValue(java.lang.String pName, java.lang.Object pValue)
Checks whether the specified qualifier is one of the qualifiers defined for this property with the specified value.boolean
isEmbeddedObject()
Returns true if the "EmbeddedObject" qualifier with true value presents.boolean
isKeyed()
Returns true if the "key" Qualifier with true value presents.
-
-
-
Constructor Detail
-
CIMQualifiedElementInterfaceImpl
public CIMQualifiedElementInterfaceImpl(CIMQualifier<?>[] pQualifiers)
Ctor. This constructor doesn't modify the passed qualifier list.- Parameters:
pQualifiers
-
-
CIMQualifiedElementInterfaceImpl
public CIMQualifiedElementInterfaceImpl(CIMQualifier<?>[] pQualifiers, boolean pIsKeyed)
Ctor. This constructor modifies the qualifier list according to the pIsKeyed flag.- Parameters:
pQualifiers
-pIsKeyed
-
-
CIMQualifiedElementInterfaceImpl
public CIMQualifiedElementInterfaceImpl(CIMQualifier<?>[] pQualifiers, boolean pIsKeyed, boolean pKeepEmbObj)
Ctor. This constructor is able to not remove the EmbeddedObject qualifier. It is useful for the XML parser to parse EmbeddedObject qualified elements without values.- Parameters:
pQualifiers
-pIsKeyed
-pKeepEmbObj
-
-
CIMQualifiedElementInterfaceImpl
public CIMQualifiedElementInterfaceImpl(CIMQualifier<?>[] pQualifiers, boolean pIsKeyed, boolean pKeepEmbObj, boolean pIsAssociation)
Ctor. This constructor is able to not remove the EmbeddedObject qualifier. It is useful for the XML parser to parse EmbeddedObject qualified elements without values. It also adds or removes the Association qualifier depending on the value of pIsAssociation.- Parameters:
pQualifiers
-pIsKeyed
-pKeepEmbObj
-pIsAssociation
-
-
-
Method Detail
-
equals
public boolean equals(java.lang.Object pObj)
- Overrides:
equals
in classjava.lang.Object
- See Also:
Object.equals(java.lang.Object)
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
- See Also:
Object.hashCode()
-
isKeyed
public boolean isKeyed()
Returns true if the "key" Qualifier with true value presents.- Returns:
- true/false
-
isEmbeddedObject
public boolean isEmbeddedObject()
Returns true if the "EmbeddedObject" qualifier with true value presents.- Returns:
- true/false
-
getQualifier
public CIMQualifier<?> getQualifier(int pIndex)
Description copied from interface:CIMQualifiedElementInterface
Get a qualifier by index.- Specified by:
getQualifier
in interfaceCIMQualifiedElementInterface
- Parameters:
pIndex
- The index of the qualifier.- Returns:
- The Qualifier at index
pIndex
. - See Also:
CIMQualifiedElementInterface.getQualifier(int)
-
getQualifier
public CIMQualifier<?> getQualifier(java.lang.String pName)
Description copied from interface:CIMQualifiedElementInterface
Gets a qualifier by name.- Specified by:
getQualifier
in interfaceCIMQualifiedElementInterface
- Parameters:
pName
- The name of the qualifier to get.- Returns:
null
if the qualifier does not exist, otherwise returns the reference to the qualifier.- See Also:
CIMQualifiedElementInterface.getQualifier(java.lang.String)
-
getQualifierCount
public int getQualifierCount()
Description copied from interface:CIMQualifiedElementInterface
Get the number of qualifiers defined for this CIM Element.- Specified by:
getQualifierCount
in interfaceCIMQualifiedElementInterface
- Returns:
- The number of qualifiers.
- See Also:
CIMQualifiedElementInterface.getQualifierCount()
-
getQualifierValue
public java.lang.Object getQualifierValue(java.lang.String pName)
Description copied from interface:CIMQualifiedElementInterface
Gets a qualifier value by name.- Specified by:
getQualifierValue
in interfaceCIMQualifiedElementInterface
- Parameters:
pName
- The name of the qualifier to get.- Returns:
null
if the qualifier does not exist or value isnull
, otherwise returns the reference to the qualifier.- See Also:
CIMQualifiedElementInterface.getQualifierValue(java.lang.String)
-
getQualifiers
public CIMQualifier<?>[] getQualifiers()
Description copied from interface:CIMQualifiedElementInterface
Returns the list of qualifiers for this class.- Specified by:
getQualifiers
in interfaceCIMQualifiedElementInterface
- Returns:
- Qualifiers for this class.
- See Also:
CIMQualifiedElementInterface.getQualifiers()
-
getQualifiers
public CIMQualifier<?>[] getQualifiers(boolean pLocalOnly)
getQualifiers - helps filtering based on the propagated flag.- Parameters:
pLocalOnly
-- Returns:
- CIMQualifier[]
-
hasQualifier
public boolean hasQualifier(java.lang.String pName)
Description copied from interface:CIMQualifiedElementInterface
Checks whether the specified qualifier is one of the qualifiers in this CIM element.- Specified by:
hasQualifier
in interfaceCIMQualifiedElementInterface
- Parameters:
pName
- The name of the qualifier.- Returns:
true
if the qualifier exists in this CIM element, otherwisefalse
.- See Also:
CIMQualifiedElementInterface.hasQualifier(java.lang.String)
-
hasQualifierValue
public boolean hasQualifierValue(java.lang.String pName, java.lang.Object pValue)
Description copied from interface:CIMQualifiedElementInterface
Checks whether the specified qualifier is one of the qualifiers defined for this property with the specified value. This method will returnfalse
if the qualifier is not applied or if the value does not match.- Specified by:
hasQualifierValue
in interfaceCIMQualifiedElementInterface
- Parameters:
pName
- The name of the qualifier.pValue
- The value to be tested.- Returns:
true
if the qualifier exists and has the value, otherwisefalse
.- See Also:
CIMQualifiedElementInterface.hasQualifierValue(java.lang.String, java.lang.Object)
-
-