javax.wbem.client
public class WBEMClientFactory extends Object
WBEMClient
factory,
which is used to retrieve a WBEMClient
for a specified protocol.
An example of how to use the factory is included below.
... WBEMClient cc = null; try { cc = WBEMClientFactory.getClient(WBEMClientConstants.PROTOCOL_CIMXML); } catch (Exception e) { System.out.println("Received error when trying to retrieve client handle"); System.exit(-1); } // initialize the client cc.initialize(cns, s, null); ...
Constructor Summary | |
---|---|
WBEMClientFactory() |
Method Summary | |
---|---|
static WBEMClient | getClient(String pProtocol)
Get a WBEMClient for a protocol.
|
static String[] | getSupportedProtocols()
Get the names of the supported protocols.
|
WBEMClient
for a protocol.
Parameters: pProtocol The protocol name (e.g. "CIM-XML").
Returns: The WBEMClient
implementation for the protocol
specified.
Throws: IllegalArgumentException
WBEMException
If the protocol implementation could not be loaded. null
or empty.
Returns: A string array of the supported protocols.