|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.hp.ucmdb.api.UcmdbServiceFactory
public class UcmdbServiceFactory
Entry point for UCMDB API services.
To obtain a reference to the UCMDB:
1) Get a reference to UcmdbServiceProvider by calling one of the getServiceProvider
methods.
2) Call one of the UcmdbServiceProvider connect
methods.
final String HOST_NAME = "localhost"; final int PORT = 8080; UcmdbServiceProvider provider = UcmdbServiceFactory.getServiceProvider(HOST_NAME, PORT); final String USERNAME = "integration_user"; final String PASSWORD = "integration_password"; Credentials credentials = provider.createCredentials(USERNAME, PASSWORD), ClientContext clientContext = provider.createClientContext("Example"); UcmdbService ucmdbService = provider.connect(credentials, clientContext);
UcmdbServiceProvider
Nested Class Summary | |
---|---|
static class |
UcmdbServiceFactory.AllHostAcceptedVerifier
Disables host name verfication (used in case of NAT networks) |
static interface |
UcmdbServiceFactory.ConnectionProperties
Internal implementation. |
static class |
UcmdbServiceFactory.DefaultTruststoreManger
The X509TrustManager implementation. |
static interface |
UcmdbServiceFactory.HttpBootstrap
Internal implementation. |
static interface |
UcmdbServiceFactory.HttpUcmdbServiceProviderFactory
Internal implementation. |
Method Summary | |
---|---|
static UcmdbServiceProvider |
getServiceProvider(java.lang.String host,
int port)
Returns an instance of a UCMDB service provider from the specified host and port. |
static UcmdbServiceProvider |
getServiceProvider(java.lang.String protocol,
java.lang.String host,
int port)
Returns an instance of a UCMDB service provider from the specified host port using the specified protocol. |
static void |
initSSL()
Initializes the secure socket layer. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static UcmdbServiceProvider getServiceProvider(java.lang.String host, int port) throws java.net.MalformedURLException, IncompatibleVersionException
host
- name of the web server host.port
- port the web server listens on. Generally 80 or 8080.
java.net.MalformedURLException
- if the host name results in an invalid URL.
IncompatibleVersionException
- if the version of the client is unsupported by the version
running on the server.public static UcmdbServiceProvider getServiceProvider(java.lang.String protocol, java.lang.String host, int port) throws java.net.MalformedURLException, IncompatibleVersionException
protocol
- either "http" or "https".host
- name of the web server host.port
- port the web server listens on. Generally 80 or 8080 for http, 443 for https.
java.net.MalformedURLException
- if the host name results in an invalid URL.
IncompatibleVersionException
- if the version of the client is unsupported by the version
running on the server.public static void initSSL()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |