|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.cics.server.HttpSession
public class HttpSession
Usage:
This class provides the Java implementation of HTTP client requests related to the following
CICS API commands:
The constructors accept either a URIMAP or a HOST string, SCHEME string and the optional PORTNUMBER value as parameters.
The setter methods allow instance variables to be set in the HttpSession object. These variables relate to the following options on the CICS API command WEB OPEN:
Method open() opens a session with a host on a remote server. The method uses the values set in the HttpSession constructor and any optional values set by the setters to open the session. This is equivalent to CICS API command WEB OPEN.
Method close() closes the session with the host on the remote server. This is equivalent to CICS API command WEB CLOSE.
If the client session has successfully been opened by the open() method getter methods can be used to obtain the following information about the open session that was saved when the session was opened or was obtained using the CICS API command WEB EXTRACT SESSTOKEN:
Field Summary | |
---|---|
static int |
HOSTNAME
Constant - HOSTNAME |
static int |
IPV4
Constant - IPV4 |
static int |
IPV6
Constant - IPV6 |
static int |
NOTAPPLIC
Constant - NOTAPPLIC |
static int |
NOTSET
Constant - NOT SET |
Constructor Summary | |
---|---|
HttpSession(java.lang.String urimap)
Usage: Sets WEB OPEN command option URIMAP. |
|
HttpSession(java.lang.String hostName,
java.lang.String scheme)
Usage: Sets WEB OPEN command option HOST and SCHEME. |
|
HttpSession(java.lang.String hostName,
java.lang.String scheme,
int portNumber)
Usage: Sets WEB OPEN command option HOST, SCHEME and PORTNUMBER. |
Method Summary | |
---|---|
void |
close()
Usage: Close a session with a host on a remote server. |
java.lang.String |
getHost()
Usage: Obtain this sessions host information. |
int |
getHostType()
Usage: Obtain this sessions hosttype information. |
int |
getHttpReleaseNumber()
Usage: Obtain this sessions HTTPRNUM value. |
int |
getHttpVersionNumber()
Usage: Obtain this sessions HTTPVNUM value. |
java.lang.String |
getPath()
Usage: Obtain this sessions path information. |
int |
getPortNumber()
Usage: Obtain this sessions port number. |
java.lang.String |
getScheme()
Usage: Obtain this sessions scheme information. |
java.lang.String |
getUrimap()
Usage: Obtain this sessions URIMAP information. |
java.lang.String |
getVersion()
Usage: Obtain this sessions version information. |
void |
open()
Usage: Open a session with a host on a remote server. |
void |
setCertificate(java.lang.String certificate)
Usage: Sets WEB OPEN command option CERTIFICATE. |
void |
setCiphers(java.lang.String ciphers,
short numberCiphers)
Usage: Sets WEB OPEN command options CIPHER and NUMCIPHERS. |
void |
setCodePage(java.lang.String codePage)
Usage: Sets WEB OPEN command option CODEPAGE. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int NOTSET
public static final int NOTAPPLIC
public static final int IPV4
public static final int IPV6
public static final int HOSTNAME
Constructor Detail |
---|
public HttpSession(java.lang.String urimap)
urimap
- is the name of the URIMAP to be used by the open() methodpublic HttpSession(java.lang.String hostName, java.lang.String scheme)
hostName
- is the name of the HOST to be used by the open() methodscheme
- should either be HTTP or HTTPSpublic HttpSession(java.lang.String hostName, java.lang.String scheme, int portNumber)
hostName
- is the name of the HOST to be used by the open() methodscheme
- should either be HTTP or HTTPSportNumber
- is the value of the PORTNUMBER to be used by the open() methodMethod Detail |
---|
public void setCodePage(java.lang.String codePage)
codePage
- is the EBCDIC code page to be used by the open() methodpublic void setCertificate(java.lang.String certificate)
certificate
- is the CERTIFICATE value to be used by the open() methodpublic void setCiphers(java.lang.String ciphers, short numberCiphers)
ciphers
- is the CIPHER value to be used by the open() methodnumberCiphers
- is the NUMCHIPERS value to be used by the open() methodpublic void open() throws InvalidRequestException, RecordNotFoundException, IOErrorException, NotAuthorisedException, LengthErrorException, TimedOutException
InvalidRequestException
- a INVREQ condition occurred
RecordNotFoundException
- a NOTFND condition occurred
IOErrorException
- a IOERR condition occurred
NotAuthorisedException
- a NOTAUTH condition occurred
LengthErrorException
- a LENGERR condition occurred
TimedOutException
- a TIMEDOUT condition occurredpublic int getHttpVersionNumber()
public int getHttpReleaseNumber()
public void close() throws InvalidRequestException, NotOpenException
InvalidRequestException
- a INVREQ condition occurred
NotOpenException
- a NOTOPEN condition occurredpublic java.lang.String getHost() throws NotOpenException
NotOpenException
- a NOTOPEN condition occurredpublic int getHostType() throws NotOpenException
NotOpenException
- a NOTOPEN condition occurredpublic java.lang.String getPath() throws NotOpenException
NotOpenException
- a NOTOPEN condition occurredpublic java.lang.String getScheme() throws NotOpenException
NotOpenException
- a NOTOPEN condition occurredpublic java.lang.String getVersion() throws NotOpenException
NotOpenException
- a NOTOPEN condition occurredpublic java.lang.String getUrimap() throws NotOpenException
NotOpenException
- a NOTOPEN condition occurredpublic int getPortNumber() throws NotOpenException
NotOpenException
- a NOTOPEN condition occurred
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |