Export (0) Print
Expand All

SWbemNamedValueSet object

An SWbemNamedValueSet object is a collection of SWbemNamedValue objects. The methods and properties of SWbemNamedValueSet are used principally to send more information to providers when submitting certain calls to WMI. All calls in SWbemServices, and some calls in SWbemObject, take an optional parameter that is an object of this type. A client can add information to an SWbemNamedValueSet object, and send the SWbemNamedValueSet object with the call as one of the parameters. This object can be created by the VBScript CreateObject call.

For more information, see Accessing a Collection.

Note  Important - If possible, do not use this mechanism because it can break the uniform access model that is the basis of WMI. If a provider does use this mechanism, it is important that this mechanism is used as sparingly as possible. If a provider requires a large amount of highly specific context information to respond to a request, all clients must be coded to provide this information. This mechanism allows you to access such providers, if necessary.

An SWbemNamedValueSet object is a collection of SWbemNamedValue elements. These items are added to the collection using the SWbemNamedValueSet.Add method. They are removed using the SWbemNamedValueSet.Remove method and retrieved using the SWbemNamedValueSet.Item method. You can access the methods to fill in any context information that is required by a dynamic provider. After you call one of the SWbemServices methods, you can reuse the SWbemNamedValueSet object for another call.

The underlying provider determines the information that is contained in an SWbemNamedValueSet object. WMI makes no use of the information, but simply forwards it to the provider. Providers must publish the context information they require to service requests.

Members

The SWbemNamedValueSet object has these types of members:

Methods

The SWbemNamedValueSet object has these methods.

MethodDescription
Add

Adds an SWbemNamedValue object to the collection.

Clone

Makes a copy of this SWbemNamedValueSet collection.

DeleteAll

Removes all items from the collection, making the SWbemNamedValueSet object empty.

Item

Retrieves an SWbemNamedValue object from the collection. This is the default method of the object.

Remove

Removes an SWbemNamedValue object from the collection.

 

Properties

The SWbemNamedValueSet object has these properties.

PropertyAccess typeDescription

Count

Read-only

The number of items in the collection.

 

Requirements

Minimum supported client

Windows XP

Minimum supported server

Windows Server 2003

Type library

Wbemdisp.tlb

DLL

Wbemdisp.dll

See also

Scripting API Objects

 

 

Show:
© 2014 Microsoft