public class MQSAPH extends com.ibm.mq.headers.internal.Header implements MQChainable
typedef struct tagMQSAPH
{
MQCHAR4 StrucId; // Structure Id
MQLONG Version; // Struct. version
MQLONG StrucLength; // Struct. length
MQLONG Encoding; // Data encoding
MQLONG CodedCharSetId; // Data CCSID
MQCHAR8 Format; // Message format
MQLONG Flags; // Flags
MQCHAR Client[SMQ_CLIENT_LEN]; // R/3 Client Id
MQCHAR Language; // R/3 language
MQCHAR48 HostName; // R/3 host name
MQCHAR12 UserId; // R/3 user Id
MQCHAR8 Password; // R/3 password
MQCHAR SystemNumber[SMQ_SYSNUM_LEN]; // R/3 systen no.
MQBYTE Reserved[2]; // Dummy field
} MQSAPH;
MQHeader.Field| Modifier and Type | Field and Description |
|---|---|
static int |
SIZE
size of an MQSAPH structure in bytes
|
static int |
SMQ_ID_LEN
Length of the client id
|
static int |
SMQ_SYSNUM_LEN
Length of the system number
|
| Constructor and Description |
|---|
MQSAPH()
Constructs an MQSAPH instance with default field values.
|
MQSAPH(java.io.DataInput message)
Constructs an MQSAPH instance populated from an MQMessage.
|
MQSAPH(java.io.DataInput message,
int encoding,
int characterSet)
Constructs an MQSAPH instance populated from a DataInput source.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
format() |
java.lang.String |
getClient()
gets the R/3 Client Id
|
int |
getCodedCharSetId()
Get the Character set identifier of data that follows.
|
int |
getEncoding()
Get the numeric encoding of the data that follows.
|
int |
getFlags()
gets the Flags
|
java.lang.String |
getFormat()
gets the Message format
|
java.lang.String |
getHostname()
gets the R/3 Host name
|
java.lang.String |
getLanguage()
gets the R/3 language
|
java.lang.String |
getPassword()
gets the R/3 Password
|
java.lang.String |
getStrucId()
Get the structure identifier; the value will be "SAPH"
|
int |
getStrucLength()
Get the length of the structure.
|
java.lang.String |
getSystemNumber()
gets the R/3 System number
|
java.lang.String |
getUserId()
gets the R/3 User id
|
int |
getVersion()
Get the Structure version number
|
int |
nextCharacterSet() |
void |
nextCharacterSet(int value)
Sets the CCSID of the next header or message content.
|
int |
nextEncoding() |
void |
nextEncoding(int value)
Sets the numeric encoding of the next header or message content.
|
java.lang.String |
nextFormat() |
void |
nextFormat(java.lang.String value)
Sets the format of the next header or message content.
|
void |
setClient(java.lang.String value)
sets the R/3 Client Id
|
void |
setCodedCharSetId(int value)
Set the Character set identifier of data that follows.
|
void |
setEncoding(int value)
Set the numeric encoding of the data that follows.
|
void |
setFlags(int value)
sets the Flags
|
void |
setFormat(java.lang.String value)
sets the Message format
|
void |
setHostname(java.lang.String value)
sets the R/3 Host name
|
void |
setLanguage(java.lang.String value)
sets the R/3 language
|
void |
setPassword(java.lang.String value)
sets the R/3 Password
|
void |
setSystemNumber(java.lang.String value)
sets the R/3 System number
|
void |
setUserId(java.lang.String value)
sets the R/3 User id
|
characterSet, encoding, fields, getBytesValue, getCharValue, getCharValue, getIntValue, getJmqiEnv, getStringValue, getValue, headerType, read, read, read, setBytesValue, setCharValue, setCharValue, setIntValue, setStringValue, setValue, size, store, store, toString, type, validate, write, writepublic static final int SMQ_ID_LEN
public static final int SMQ_SYSNUM_LEN
public static final int SIZE
public MQSAPH()
public MQSAPH(java.io.DataInput message)
throws MQDataException,
java.io.IOException
message - the message to readMQDataException - if the message content does not yield a valid MQSAPH stucturejava.io.IOException - if there is a problem reading the message contentpublic MQSAPH(java.io.DataInput message,
int encoding,
int characterSet)
throws MQDataException,
java.io.IOException
message - the MQMessage or other DataInput source to readencoding - the initial numeric encoding of the data in the messagecharacterSet - the initial CCSID of the data in the messageMQDataException - if the message content does not yield a valid MQSAPH stucturejava.io.IOException - if there is a problem reading the message contentpublic java.lang.String getStrucId()
public int getVersion()
public int getStrucLength()
public int getEncoding()
public void setEncoding(int value)
value - the numeric encoding. A combination of MQENC_* values.public int getCodedCharSetId()
public void setCodedCharSetId(int value)
value - the Character set identifier.public java.lang.String getFormat()
public void setFormat(java.lang.String value)
value - the Message formatpublic int getFlags()
public void setFlags(int value)
value - the Flagspublic java.lang.String getClient()
public void setClient(java.lang.String value)
value - the R/3 Client Idpublic java.lang.String getLanguage()
public void setLanguage(java.lang.String value)
value - the R/3 languagepublic java.lang.String getHostname()
public void setHostname(java.lang.String value)
value - the R/3 Host namepublic java.lang.String getUserId()
public void setUserId(java.lang.String value)
value - the R/3 User idpublic java.lang.String getPassword()
public void setPassword(java.lang.String value)
value - public java.lang.String getSystemNumber()
public void setSystemNumber(java.lang.String value)
value - the R/3 System numberpublic int nextEncoding()
nextEncoding in interface MQChainableMQChainable.nextEncoding()public void nextEncoding(int value)
MQChainablenextEncoding in interface MQChainableMQChainable.nextEncoding(int)public int nextCharacterSet()
nextCharacterSet in interface MQChainableMQChainable.nextCharacterSet()public void nextCharacterSet(int value)
MQChainablenextCharacterSet in interface MQChainableMQChainable.nextCharacterSet(int)public java.lang.String nextFormat()
nextFormat in interface MQChainableMQChainable.nextFormat()public void nextFormat(java.lang.String value)
MQChainablenextFormat in interface MQChainableMQChainable.nextFormat(java.lang.String)public java.lang.String format()
format in interface MQChainableMQChainable.format()