Primavera Integration API 7.0

com.primavera.integration.client
Class RMIURL

java.lang.Object
  extended by com.primavera.integration.client.RMIURL

public class RMIURL
extends java.lang.Object

This helper class is used to generate the URL for Remote Mode required by Session's getDatabaseInstances() and login() methods. The service mode used (standard, compression, SSL, HTTP, or HTTPS) is differentiated by the URL. HTTP and HTTPS modes are used with HTTP tunneling, which encapsulates RMI calls in HTTP, allowing RMI to communicate through a firewall with only one required open port.


Field Summary
static int COMPRESSION_RMI_SERVICE
          Compression service mode.
static int HTTP_RMI_SERVICE
          Deprecated. HTTP service mode. As of release 7.0, the Standard or Compression service modes should be used instead of the HTTP service mode. HTTP tunneling will be removed in a future release.
static int HTTPS_RMI_SERVICE
          Deprecated. HTTPS service mode. As of release 7.0, the SSL service mode should be used instead of the HTTPS service mode. HTTPS tunneling will be removed in a future release.
static int LOCAL_SERVICE
          Local mode.
static int SSL_RMI_SERVICE
          SSL service mode.
static int STANDARD_RMI_SERVICE
          Standard service mode.
 
Method Summary
static java.lang.String getDefaultHost()
          Gets the default RMI registry host.
static int getDefaultPort()
          Gets the default RMI registry port number.
static java.lang.String getRmiUrl()
          Return the default URL for an RMI standard service 'RemoteSession'.
static java.lang.String getRmiUrl(int iMode)
          Return the URL for an RMI service 'RemoteSession' for the specified service mode using the default host and port.
static java.lang.String getRmiUrl(int iMode, java.lang.String sHost, int iPort)
          Return the URL for an RMI service 'RemoteSession' for the specified service mode, host and port.
static java.lang.String getRmiUrl(int iMode, java.lang.String sHost, int iRMIPort, int iHttpPort)
          Return the HTTP tunneling URL for an RMI service 'RemoteSession' for the specified service mode, host and port.
static void setDefaultHost(java.lang.String sHost)
          Sets the default RMI registry host.
static void setDefaultPort(int iPort)
          Sets the default RMI registry port number.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOCAL_SERVICE

public static final int LOCAL_SERVICE
Local mode.

See Also:
Constant Field Values

STANDARD_RMI_SERVICE

public static final int STANDARD_RMI_SERVICE
Standard service mode.

See Also:
Constant Field Values

COMPRESSION_RMI_SERVICE

public static final int COMPRESSION_RMI_SERVICE
Compression service mode.

See Also:
Constant Field Values

SSL_RMI_SERVICE

public static final int SSL_RMI_SERVICE
SSL service mode.

See Also:
Constant Field Values

HTTP_RMI_SERVICE

@Deprecated
public static final int HTTP_RMI_SERVICE
Deprecated. HTTP service mode. As of release 7.0, the Standard or Compression service modes should be used instead of the HTTP service mode. HTTP tunneling will be removed in a future release.
See Also:
Constant Field Values

HTTPS_RMI_SERVICE

@Deprecated
public static final int HTTPS_RMI_SERVICE
Deprecated. HTTPS service mode. As of release 7.0, the SSL service mode should be used instead of the HTTPS service mode. HTTPS tunneling will be removed in a future release.
See Also:
Constant Field Values
Method Detail

getRmiUrl

public static java.lang.String getRmiUrl()
Return the default URL for an RMI standard service 'RemoteSession'.

Returns:
the default URL for an RMI standard service

getRmiUrl

public static java.lang.String getRmiUrl(int iMode)
Return the URL for an RMI service 'RemoteSession' for the specified service mode using the default host and port.

Parameters:
iMode - indicates standard/compression/SSL mode
Returns:
the URL for an RMI service

getRmiUrl

public static java.lang.String getRmiUrl(int iMode,
                                         java.lang.String sHost,
                                         int iPort)
Return the URL for an RMI service 'RemoteSession' for the specified service mode, host and port.

Parameters:
iMode - indicates standard/compression/SSL mode
sHost - the RMI registry host
iPort - the RMI registry port number
Returns:
the URL for an RMI service
Throws:
java.lang.IllegalArgumentException - if the host parameter is null

getRmiUrl

public static java.lang.String getRmiUrl(int iMode,
                                         java.lang.String sHost,
                                         int iRMIPort,
                                         int iHttpPort)
Return the HTTP tunneling URL for an RMI service 'RemoteSession' for the specified service mode, host and port.

Parameters:
iMode - indicates HTTP/HTTPS mode
sHost - the HTTP/RMI host
iRMIPort - the RMI registry port number
iHttpPort - the HTTP port number which is used for HTTP/HTTPS tunneling mode only
Returns:
the HTTP URL for an RMI service
Throws:
java.lang.IllegalArgumentException - if the host parameter is null

getDefaultHost

public static java.lang.String getDefaultHost()
Gets the default RMI registry host.

Returns:
the default RMI registry host

setDefaultHost

public static void setDefaultHost(java.lang.String sHost)
Sets the default RMI registry host.

Parameters:
sHost - the new default RMI registry host
Throws:
java.lang.IllegalArgumentException - if the host parameter is null

getDefaultPort

public static int getDefaultPort()
Gets the default RMI registry port number.

Returns:
the default RMI registry port number

setDefaultPort

public static void setDefaultPort(int iPort)
Sets the default RMI registry port number.

Parameters:
iPort - the new default RMI registry port number

Primavera Integration API 7.0

Copyright © 2003, 2009, Oracle and/or its affiliates. All rights reserved.