public class CIMObjectPath
extends java.lang.Object
implements java.io.Serializable
http://myserver/root/cimv2:My_ComputerSystem.Name=mycomputer,
CreationClassName=My_ComputerSystem
http://myserver/root/cimv2
- Specifies the
"root/cimv2"
namespace on the host myserver
.My_ComputerSystem.Name=mycomputer,CreationClassName=My_ComputerSystem
- Specifies a My_ComputerSystem
object which is
uniquely identified by two key properties and their corresponding values in
the format (key=value): Name=mycomputer
CreationClassName=My_ComputerSystem
Constructor and Description |
---|
CIMObjectPath(java.lang.String pObjectPath)
Constructs a CIM Object Path referencing a CIM element.
|
CIMObjectPath(java.lang.String pObjectName,
java.lang.String pNamespace)
Constructs a CIM Object Path referencing a CIM element along in the
specified namespace.
|
CIMObjectPath(java.lang.String pObjectName,
java.lang.String pNamespace,
CIMProperty<?>[] pKeys)
Constructs a CIM Object Path referencing an instance of the specified CIM
element as defined in the specified namespace and identified by the given
key properties and their corresponding values.
NOTE: When using this API against OpenPegasus CIMOM, do not provide the preceding '/' in the namespace parameter. |
CIMObjectPath(java.lang.String pHost,
java.lang.String pNamespace,
java.lang.String pObjectName,
CIMProperty<?>[] pKeys)
Constructs a CIM Object Path referencing an instance of the specified CIM
element as defined in the specified namespace on the specified host and
identified by the given key properties and their corresponding values.
NOTE: When using this API against OpenPegasus CIMOM, do not provide the preceding '/' in the namespace parameter. |
CIMObjectPath(java.lang.String pScheme,
java.lang.String pHost,
java.lang.String pPort,
java.lang.String pNamespace,
java.lang.String pObjectName,
CIMProperty<?>[] pKeys)
Constructs a CIM Object Path referencing an instance of the specified CIM
element as defined in the specified namespace on the specified host and
identified by the given key properties and their corresponding values.
|
CIMObjectPath(java.lang.String pScheme,
java.lang.String pHost,
java.lang.String pPort,
java.lang.String pNamespace,
java.lang.String pObjectName,
CIMProperty<?>[] pKeys,
java.lang.String pXmlSchemaName)
Constructs a CIM Object Path referencing an instance of the specified CIM
element as defined in the specified namespace on the specified host and
identified by the given key properties and their corresponding values.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object pObj)
Compares this CIM object path with the specified CIM object path for
equality.
|
boolean |
equalsModelPath(CIMObjectPath pModelPath)
Compares this model path with the specified model path for equality.
|
java.lang.String |
getHost()
Gets the host.
|
CIMProperty<?> |
getKey(java.lang.String pName)
Gets a key property by name.
|
CIMProperty<?>[] |
getKeys()
Gets all key properties.
|
java.lang.Object |
getKeyValue(java.lang.String pName) |
java.lang.String |
getNamespace()
Gets the namespace.
|
java.lang.String |
getObjectName()
Gets the object name.
|
java.lang.String |
getPort()
Gets the the port on the host to which the connection was established.
|
java.lang.String |
getScheme()
Get the connection scheme.
|
java.lang.String |
getXmlSchemaName()
Get the XML Schema for this object (optional).
|
int |
hashCode()
Computes the hash code for this object path.
|
java.lang.String |
toString()
Returns a
String representation of the CIM object path. |
public CIMObjectPath(java.lang.String pObjectPath)
http://myserver.org:5066/root/cimv2:My_ComputerSystem.Name="mycmp",CreationClassName="My_ComputerSystem"
http://myserver.org/root/cimv2:My_ComputerSystem.Name="mycmp",CreationClassName="My_ComputerSystem"
//myserver.org/root/cimv2:My_ComputerSystem
/root/cimv2:My_ComputerSystem
pObjectPath
- The string representation of an object path for a CIM element
that will be parsed and used to initialize the object.public CIMObjectPath(java.lang.String pObjectName, java.lang.String pNamespace)
"root/cimv2"
as a namespace but will not accept
"/root/cimv2"
.pObjectName
- The name of a CIM element.pNamespace
- The namespace relative to the current namespace.public CIMObjectPath(java.lang.String pObjectName, java.lang.String pNamespace, CIMProperty<?>[] pKeys)
"root/cimv2"
as a namespace but will not accept
"/root/cimv2"
.pObjectName
- The name of the CIM element referenced.pNamespace
- The namespace in which the CIM element is defined.pKeys
- The keys and their corresponding values that identify an
instance of the CIM element.public CIMObjectPath(java.lang.String pHost, java.lang.String pNamespace, java.lang.String pObjectName, CIMProperty<?>[] pKeys)
"root/cimv2"
as a namespace but will not accept
"/root/cimv2"
.pHost
- The host name or IP Address.pNamespace
- The namepace in which the CIM element is defined.pObjectName
- The name of the CIM element referenced.pKeys
- The keys and their corresponding values that identify an
instance of the CIM element.public CIMObjectPath(java.lang.String pScheme, java.lang.String pHost, java.lang.String pPort, java.lang.String pNamespace, java.lang.String pObjectName, CIMProperty<?>[] pKeys)
"root/cimv2"
as a namespace but will not accept
"/root/cimv2"
.pScheme
- The connection scheme to the host (e.g. http, https, ...)pHost
- The host name or IP Address.pPort
- The port on the host to which the connection was established.pNamespace
- The namepace in which the CIM element is defined.pObjectName
- The name of the CIM element referenced.pKeys
- The keys and their corresponding values that identify an
instance of the CIM element.public CIMObjectPath(java.lang.String pScheme, java.lang.String pHost, java.lang.String pPort, java.lang.String pNamespace, java.lang.String pObjectName, CIMProperty<?>[] pKeys, java.lang.String pXmlSchemaName)
"root/cimv2"
as a namespace but will not accept
"/root/cimv2"
.pScheme
- The connection scheme to the host (e.g. http, https, ...)pHost
- The host name or IP Address.pPort
- The port on the host to which the connection was established.pNamespace
- The namepace in which the CIM element is defined.pObjectName
- The name of the CIM element referenced.pKeys
- The keys and their corresponding values that identify an
instance of the CIM element.pXmlSchemaName
- The name of the XML Schema for this object. This is only
needed for protocols that require this information.public boolean equals(java.lang.Object pObj)
equals
in class java.lang.Object
pObj
- The object to compare to this CIM object path. Only the model
paths are compared.true
if the specified path references the same
object, otherwise false
is returned.public boolean equalsModelPath(CIMObjectPath pModelPath)
pModelPath
- The object to compare.true
if the specified path references the same
object, otherwise false
.public java.lang.String getHost()
public CIMProperty<?> getKey(java.lang.String pName)
pName
- The name of the key property to retrieve.CIMProperty
with the given name, or
null
if it is not found.public CIMProperty<?>[] getKeys()
public java.lang.Object getKeyValue(java.lang.String pName)
pName
- The name of the key property to retrieve.public java.lang.String getNamespace()
public java.lang.String getObjectName()
public java.lang.String getPort()
public java.lang.String getScheme()
public java.lang.String getXmlSchemaName()
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
String
representation of the CIM object path. This
method is intended to be used only for debugging purposes. The format of
the value returned may vary between implementations. The string returned
may be empty but may not be null
.toString
in class java.lang.Object
Copyright © 2005, 2012 IBM Corporation. All Rights Reserved.