OW_NAMESPACE::CIMNameSpaceUtils Namespace Reference


Functions

String prepareNamespace (const String &ns)
 This function creates a "normalized" namespace.
void createCIM_Namespace (CIMOMHandleIFC &hdl, const String &ns, UInt16 classInfo=0, const String &descriptionOfClassInfo="", const String &interopNs=OW_DEFAULT_INTEROP_SCHEMA_NAMESPACE)
 Create a cim namespace by creating an instance of the CIM_Namespace class.
void deleteCIM_Namespace (CIMOMHandleIFC &hdl, const String &ns, const String &interopNs=OW_DEFAULT_INTEROP_SCHEMA_NAMESPACE)
 Delete a specified namespace by deleting an instance of the CIM_Namespace class.
StringArray enumCIM_Namespace (CIMOMHandleIFC &hdl, const String &interopNs=OW_DEFAULT_INTEROP_SCHEMA_NAMESPACE)
 Gets a list of the namespaces by enumerating the instances of the CIM_Namespace class.
void enumCIM_Namespace (CIMOMHandleIFC &hdl, StringResultHandlerIFC &result, const String &interopNs=OW_DEFAULT_INTEROP_SCHEMA_NAMESPACE)
 Gets a list of the namespaces by enumerating the instances of the CIM_Namespace class.
void create__Namespace (CIMOMHandleIFC &hdl, const String &ns)
 Create a cim namespace by creating an instance of the __Namespace class.
void delete__Namespace (CIMOMHandleIFC &hdl, const String &ns)
 Delete a specified namespace by deleting an instance of the __Namespace class.
StringArray enum__Namespace (CIMOMHandleIFC &hdl, const String &ns, EDeepFlag deep)
void enumNameSpaceAux (CIMOMHandleIFC &hdl, const String &ns, StringResultHandlerIFC &result, EDeepFlag deep)
void enum__Namespace (CIMOMHandleIFC &hdl, const String &ns_, StringResultHandlerIFC &result, EDeepFlag deep)
OW_COMMON_API StringArray enum__Namespace (CIMOMHandleIFC &hdl, const String &ns, WBEMFlags::EDeepFlag deep=WBEMFlags::E_DEEP)
 Gets a list of the namespaces by enumerating the instances of the __Namespace class.
OW_COMMON_API void enum__Namespace (CIMOMHandleIFC &hdl, const String &ns, StringResultHandlerIFC &result, WBEMFlags::EDeepFlag deep=WBEMFlags::E_DEEP)
 Gets a list of the namespaces by enumerating the instances of the __Namespace class.

Variables

CIMClass the__NamespaceClass (CIMNULL)
const char *const DEPRECATED__NamespaceClassName = "__Namespace"


Function Documentation

OW_COMMON_API void OW_NAMESPACE::CIMNameSpaceUtils::create__Namespace CIMOMHandleIFC &  hdl,
const String &  ns
 

Create a cim namespace by creating an instance of the __Namespace class.

This method has been deprecated in the CIM Ops spec. This implementation assumes that __Namespace presents a hierarcial view of the namespaces.

Parameters:
hdl The cimom handle that will be used.
ns The namespace name to be created.
Exceptions:
CIMException If the namespace already exists.

Definition at line 193 of file OW_CIMNameSpaceUtils.cpp.

References OW_NAMESPACE::CIMClass::addProperty(), OW_NAMESPACE::CIMProperty::addQualifier(), DEPRECATED__NamespaceClassName, hdl, index, OW_NAMESPACE::String::lastIndexOf(), OW_NAMESPACE::CIMClass::newInstance(), ns, prepareNamespace(), OW_NAMESPACE::CIMProperty::setDataType(), OW_NAMESPACE::CIMInstance::setProperty(), OW_NAMESPACE::STRING, OW_NAMESPACE::String::substring(), and the__NamespaceClass.

Referenced by OW_NAMESPACE::MOF::CIMOMVisitor::CIMOMcreateNamespace(), OW_NAMESPACE::ClientCIMOMHandle::createNameSpace(), and OW_NAMESPACE::CIMClient::createNameSpace().

OW_COMMON_API void OW_NAMESPACE::CIMNameSpaceUtils::createCIM_Namespace CIMOMHandleIFC &  hdl,
const String &  ns,
UInt16  classInfo = 0,
const String &  descriptionOfClassInfo = "",
const String &  interopNs = OW_DEFAULT_INTEROP_SCHEMA_NAMESPACE
 

Create a cim namespace by creating an instance of the CIM_Namespace class.

Parameters:
hdl The cimom handle that will be used.
ns The namespace name to be created.
classInfo [Required, Write, Description ( "Enumeration indicating the organization/schema of the " "Namespace's objects. For example, they may be instances " "of classes of a specific CIM version."), ValueMap {"0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "200", "201", "202"}, Values {"Unknown", "Other", "CIM 1.0", "CIM 2.0", "CIM 2.1", "CIM 2.2", "CIM 2.3", "CIM 2.4", "CIM 2.5", "CIM 2.6", "DMI Recast", "SNMP Recast", "CMIP Recast"}, ModelCorrespondence {"CIM_Namespace.DescriptionOfClassInfo"} ]
descriptionOfClassInfo [Write, Description ( "A string providing more detail (beyond the general " "classification in ClassInfo) for the object hierarchy of " "the Namespace."), ModelCorrespondence {"CIM_Namespace.ClassInfo"} ]
interopNS The interop namespace which contains the CIM_Namespace class & instances. The default is root because the CIM Ops. spec says: "It is the common practice proposed by this document that instances of CIM_Namespace be created in root unless there is a specific reason to define them in another namespace."
Exceptions:
CIMException If the namespace already exists.

Definition at line 106 of file OW_CIMNameSpaceUtils.cpp.

References hdl, ns, OW_NAMESPACE::Enumeration< T >::numberOfElements(), OW_THROWCIMMSG, and prepareNamespace().

Referenced by OW_NAMESPACE::MOF::CIMOMVisitor::CIMOMcreateNamespace(), and OW_NAMESPACE::CIMClient::createNameSpace().

OW_COMMON_API void OW_NAMESPACE::CIMNameSpaceUtils::delete__Namespace CIMOMHandleIFC &  hdl,
const String &  ns
 

Delete a specified namespace by deleting an instance of the __Namespace class.

This method has been deprecated in the CIM Ops spec. This implementation assumes that __Namespace presents a hierarcial view of the namespaces.

Parameters:
hdl The cimom handle that will be used.
ns The namespace to delete.
Exceptions:
CIMException If the namespace does not exist.

Definition at line 214 of file OW_CIMNameSpaceUtils.cpp.

References DEPRECATED__NamespaceClassName, hdl, index, OW_NAMESPACE::String::lastIndexOf(), ns, prepareNamespace(), OW_NAMESPACE::Array< T >::push_back(), OW_NAMESPACE::CIMProperty::setDataType(), OW_NAMESPACE::STRING, and OW_NAMESPACE::String::substring().

Referenced by OW_NAMESPACE::ClientCIMOMHandle::deleteNameSpace(), and OW_NAMESPACE::CIMClient::deleteNameSpace().

OW_COMMON_API void OW_NAMESPACE::CIMNameSpaceUtils::deleteCIM_Namespace CIMOMHandleIFC &  hdl,
const String &  ns,
const String &  interopNs = OW_DEFAULT_INTEROP_SCHEMA_NAMESPACE
 

Delete a specified namespace by deleting an instance of the CIM_Namespace class.

The namespace must be empty of all classes and instances before it can be deleted.

Parameters:
hdl The cimom handle that will be used.
ns The namespace to delete.
interopNS The interop namespace which contains the CIM_Namespace class & instances. The default is root because the CIM Ops. spec says: "It is the common practice proposed by this document that instances of CIM_Namespace be created in root unless there is a specific reason to define them in another namespace."
Exceptions:
CIMException If the namespace does not exist.

Definition at line 138 of file OW_CIMNameSpaceUtils.cpp.

References hdl, ns, OW_NAMESPACE::Enumeration< T >::numberOfElements(), OW_THROWCIMMSG, and prepareNamespace().

Referenced by OW_NAMESPACE::CIMClient::deleteNameSpace().

OW_COMMON_API void OW_NAMESPACE::CIMNameSpaceUtils::enum__Namespace CIMOMHandleIFC &  hdl,
const String &  ns,
StringResultHandlerIFC result,
WBEMFlags::EDeepFlag  deep = WBEMFlags::E_DEEP
 

Gets a list of the namespaces by enumerating the instances of the __Namespace class.

This method has been deprecated in the CIM Ops spec. This implementation assumes that __Namespace presents a hierarcial view of the namespaces.

Parameters:
hdl The cimom handle that will be used.
ns The parent namespace to enumerate
result result.handle will be called once for each enumerated namespace.
deep If set to DEEP, the enumeration returned will contain the entire hierarchy of namespaces present under the enumerated namespace. If set to SHALLOW the enuermation will return only the first level children of the enumerated namespace.
Exceptions:
CIMException If the namespace does not exist or the object cannot be found in the specified namespace.

OW_COMMON_API StringArray OW_NAMESPACE::CIMNameSpaceUtils::enum__Namespace CIMOMHandleIFC &  hdl,
const String &  ns,
WBEMFlags::EDeepFlag  deep = WBEMFlags::E_DEEP
 

Gets a list of the namespaces by enumerating the instances of the __Namespace class.

This method has been deprecated in the CIM Ops spec. This implementation assumes that __Namespace presents a hierarcial view of the namespaces.

Parameters:
hdl The cimom handle that will be used.
ns The parent namespace to enumerate
deep If set to DEEP, the enumeration returned will contain the entire hierarchy of namespaces present under the enumerated namespace. If set to SHALLOW the enuermation will return only the first level children of the enumerated namespace.
Returns:
An Array of namespace names as strings.
Exceptions:
CIMException If the namespace does not exist or the object cannot be found in the specified namespace.

void OW_NAMESPACE::CIMNameSpaceUtils::enum__Namespace CIMOMHandleIFC &  hdl,
const String &  ns_,
StringResultHandlerIFC result,
EDeepFlag  deep
 

Definition at line 275 of file OW_CIMNameSpaceUtils.cpp.

References enumNameSpaceAux(), OW_NAMESPACE::ResultHandlerIFC< T >::handle(), hdl, ns, prepareNamespace(), and result.

StringArray OW_NAMESPACE::CIMNameSpaceUtils::enum__Namespace CIMOMHandleIFC &  hdl,
const String &  ns,
EDeepFlag  deep
 

Definition at line 231 of file OW_CIMNameSpaceUtils.cpp.

References handler, hdl, and ns.

Referenced by OW_NAMESPACE::CIMClient::enumCIM_Namespace(), OW_NAMESPACE::CIMClient::enumCIM_NamespaceE(), OW_NAMESPACE::ClientCIMOMHandle::enumNameSpace(), OW_NAMESPACE::CIMClient::enumNameSpace(), and OW_NAMESPACE::CIMClient::enumNameSpaceE().

OW_COMMON_API void OW_NAMESPACE::CIMNameSpaceUtils::enumCIM_Namespace CIMOMHandleIFC &  hdl,
StringResultHandlerIFC result,
const String &  interopNs = OW_DEFAULT_INTEROP_SCHEMA_NAMESPACE
 

Gets a list of the namespaces by enumerating the instances of the CIM_Namespace class.

Parameters:
hdl The cimom handle that will be used.
result result.handle will be called once for each enumerated namespace.
interopNS The interop namespace which contains the CIM_Namespace class & instances. The default is root because the CIM Ops. spec says: "It is the common practice proposed by this document that instances of CIM_Namespace be created in root unless there is a specific reason to define them in another namespace."
Exceptions:
CIMException If the namespace does not exist or the object cannot be found in the specified namespace.

Definition at line 179 of file OW_CIMNameSpaceUtils.cpp.

References handler, hdl, and result.

OW_COMMON_API StringArray OW_NAMESPACE::CIMNameSpaceUtils::enumCIM_Namespace CIMOMHandleIFC &  hdl,
const String &  interopNs = OW_DEFAULT_INTEROP_SCHEMA_NAMESPACE
 

Gets a list of the namespaces by enumerating the instances of the CIM_Namespace class.

Parameters:
hdl The cimom handle that will be used.
interopNS The interop namespace which contains the CIM_Namespace class & instances. The default is root because the CIM Ops. spec says: "It is the common practice proposed by this document that instances of CIM_Namespace be created in root unless there is a specific reason to define them in another namespace."
Returns:
An Array of namespace names as strings.
Exceptions:
CIMException If the namespace does not exist or the object cannot be found in the specified namespace.

Definition at line 170 of file OW_CIMNameSpaceUtils.cpp.

References handler, and hdl.

Referenced by OW_NAMESPACE::CIMClient::enumCIM_Namespace(), and OW_NAMESPACE::CIMClient::enumCIM_NamespaceE().

void OW_NAMESPACE::CIMNameSpaceUtils::@2::enumNameSpaceAux CIMOMHandleIFC &  hdl,
const String &  ns,
StringResultHandlerIFC result,
EDeepFlag  deep
[static]
 

Definition at line 242 of file OW_CIMNameSpaceUtils.cpp.

References DEPRECATED__NamespaceClassName, OW_NAMESPACE::WBEMFlags::E_LOCAL_ONLY, OW_NAMESPACE::WBEMFlags::E_SHALLOW, OW_NAMESPACE::CIMValue::getType(), OW_NAMESPACE::Enumeration< T >::hasMoreElements(), hdl, i, OW_NAMESPACE::CIMValue::isArray(), OW_NAMESPACE::Enumeration< T >::nextElement(), ns, OW_THROWCIMMSG, and OW_NAMESPACE::STRING.

Referenced by enum__Namespace().

OW_COMMON_API String OW_NAMESPACE::CIMNameSpaceUtils::prepareNamespace const String &  ns  ) 
 

This function creates a "normalized" namespace.

Because of differing WBEM implementations, it's expected that the following all refer to the same namespace: root, /root, and . As far as the openwbem cimom is concerned, they are all different, so this function translates all backslashes to forward slashes and also removes all beginning slashes. So /root and yield just root.

Parameters:
ns The namespace name.
Returns:
ns The normalized version of ns.

Definition at line 86 of file OW_CIMNameSpaceUtils.cpp.

References i, OW_NAMESPACE::String::length(), and ns.

Referenced by OW_NAMESPACE::BinaryCIMOMHandle::associatorNames(), OW_NAMESPACE::BinaryCIMOMHandle::associators(), OW_NAMESPACE::BinaryCIMOMHandle::associatorsClasses(), create__Namespace(), createCIM_Namespace(), OW_NAMESPACE::BinaryCIMOMHandle::createClass(), OW_NAMESPACE::BinaryCIMOMHandle::createInstance(), delete__Namespace(), deleteCIM_Namespace(), OW_NAMESPACE::BinaryCIMOMHandle::deleteClass(), OW_NAMESPACE::BinaryCIMOMHandle::deleteInstance(), OW_NAMESPACE::BinaryCIMOMHandle::deleteQualifierType(), enum__Namespace(), OW_NAMESPACE::BinaryCIMOMHandle::enumClass(), OW_NAMESPACE::BinaryCIMOMHandle::enumClassNames(), OW_NAMESPACE::BinaryCIMOMHandle::enumInstanceNames(), OW_NAMESPACE::BinaryCIMOMHandle::enumInstances(), OW_NAMESPACE::BinaryCIMOMHandle::enumQualifierTypes(), OW_NAMESPACE::BinaryCIMOMHandle::execQuery(), OW_NAMESPACE::BinaryCIMOMHandle::getClass(), OW_NAMESPACE::BinaryCIMOMHandle::getInstance(), OW_NAMESPACE::BinaryCIMOMHandle::getProperty(), OW_NAMESPACE::BinaryCIMOMHandle::getQualifierType(), OW_NAMESPACE::getSourceNameSpace(), OW_NAMESPACE::BinaryCIMOMHandle::invokeMethod(), OW_NAMESPACE::BinaryCIMOMHandle::modifyClass(), OW_NAMESPACE::BinaryCIMOMHandle::modifyInstance(), OW_NAMESPACE::BinaryCIMOMHandle::referenceNames(), OW_NAMESPACE::BinaryCIMOMHandle::references(), OW_NAMESPACE::BinaryCIMOMHandle::referencesClasses(), OW_NAMESPACE::BinaryCIMOMHandle::setProperty(), and OW_NAMESPACE::BinaryCIMOMHandle::setQualifierType().


Variable Documentation

const char* const OW_NAMESPACE::CIMNameSpaceUtils::DEPRECATED__NamespaceClassName = "__Namespace" [static]
 

Definition at line 189 of file OW_CIMNameSpaceUtils.cpp.

Referenced by create__Namespace(), delete__Namespace(), and enumNameSpaceAux().

CIMClass OW_NAMESPACE::CIMNameSpaceUtils::the__NamespaceClass(CIMNULL) [static]
 

Referenced by create__Namespace().


Generated on Thu Feb 9 09:17:12 2006 for openwbem by  doxygen 1.4.6