|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.a2zss.ISO8583.ISO8583II
public class ISO8583II
This class can be used as parser and formatter
Field Summary |
---|
Fields inherited from interface com.a2zss.ISO8583.ISOConstants |
---|
AUTHORISATION, AUTHORISATION_REPEAT, AUTHORISATION_RESPONSE, CASH_ADVANCE, CLEARING_REQUEST, CLEARING_REQUEST_RESPONSE, ENC_CODED, ENC_LLLLPLAIN, ENC_PACKED, ENC_PLAIN, mandatoryBits, MSG_MAX_LENGTH, MTID, MTISTRING, NETWORK_REQUEST, NETWORK_RESPONSE, optionalBits, ORDINAL_PURCHASE, PROCS, PROCSTR, REVAERSAL_RESPONSE, REVERSAL, REVERSAL_REPEAT, SMS_AUTHORISATION, SMS_AUTHORISATION_REPEAT, SMS_AUTHORISATION_RESPONSE, UNATTENDED_PURCHASE, V1987, V1993, V2003 |
Constructor Summary | |
---|---|
ISO8583II()
Class constructor |
|
ISO8583II(Config con)
Class constructor |
Method Summary | |
---|---|
byte[] |
createBinLenPackedValue(ISOField f)
Method createBinLenPackedValue |
byte[] |
createPackedValue(ISOField f)
|
byte[] |
formatEncoded(Message msg)
Formats message in packed and encoded format |
byte[] |
formatLLLLPlain(Message msg)
Formats the message in plain format with 4 byte length Note: supports fields FH_IDENT, FH_DCP, FF_FOT if they are configured |
byte[] |
formatLLPlain(Message msg)
Formats the message in plain format with two byte length Note: supports fields FH_IDENT, FH_DCP, FF_FOT if they are configured |
byte[] |
formatPacked(Message msg)
Method to format message in packed format |
byte[] |
formatPlain(Message msg)
Formats the message in plain format Note: supports fields FH_IDENT, FH_DCP, FF_FOT if they are configured |
Config |
getConfig()
|
int |
getDebuglevel()
|
byte[] |
getEncoded(byte[] in)
gets the encoded data block from syntax 2 |
byte[] |
getEncoded(java.io.InputStream is)
gets the encoded data block from syntax 2 encoded stream |
int |
getEncodingType(byte[] msg)
checks the ISO message encoding type from bye[] array |
int |
getEncodingType(java.io.PushbackInputStream is)
checks the ISO message encoding type from stream |
java.io.PrintStream |
getOutput()
|
Message |
parseLLLLPlain(java.io.InputStream is)
parses the LLLLplain format from inputstream Note: supports fields FH_IDENT, FH_DCP, FF_FOTif they are configured |
Message |
parseLLPlain(java.io.InputStream is)
parses the LLplain format from inputstream (where LL is two byte (packed/binary length) Note: supports fields FH_IDENT, FH_DCP, FF_FOTif they are configured |
Message |
parsePacked(byte[] in)
parses the packed ISO8583 format from buffer |
Message |
parsePacked(java.io.InputStream is)
parses the packed ISO8583 format from stream |
Message |
parsePlain(byte[] buf)
parses the plain format from byte buffer Note: supports fields FH_IDENT, FH_DCP, FF_FOT if they are configured |
Message |
parsePlain(java.io.InputStream is)
parses the plain format from inputstream Note: supports fields FH_IDENT, FH_DCP, FF_FOT if they are configured |
ISOField |
parsePlainField(java.io.DataInputStream dis,
int i,
int ver)
Parses current field from underlying stream from its currecnt position (used internally) |
Message |
parseStream(java.io.InputStream is)
Parses and detects near any ISO8583 format from InputStream (without custom headers used) recognizes automatically messages without headers and with length in plain or encoded fromat Messages with header fields before MTI cannot be parsed with this |
void |
setConfig(Config con)
|
void |
setDebuglevel(int debuglevel)
|
void |
setOutput(java.io.PrintStream os)
Set the debug output stream |
void |
validateFields(Message flds)
validates if the fields Message contains reflect the type and format required or if there are fields not compatible with required length and type then throws an ISOException |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ISO8583II()
public ISO8583II(Config con)
con
- - hte configuration to useMethod Detail |
---|
public void setConfig(Config con)
con
- public Config getConfig()
public void setOutput(java.io.PrintStream os)
os
- public java.io.PrintStream getOutput()
public int getDebuglevel()
public void setDebuglevel(int debuglevel)
debuglevel
- The debuglevel to set. (0..5)public final int getEncodingType(java.io.PushbackInputStream is) throws java.lang.Exception
is
- the message data stream
java.lang.Exception
- if errorpublic final int getEncodingType(byte[] msg) throws java.lang.Exception
msg
- the message data
java.lang.Exception
public final byte[] getEncoded(byte[] in) throws java.lang.Exception
in
-
java.lang.Exception
public final byte[] getEncoded(java.io.InputStream is) throws java.lang.Exception
is
-
java.lang.Exception
public final byte[] formatPacked(Message msg) throws java.lang.Exception
msg
- the message object with fields to format
java.lang.Exception
public final byte[] formatEncoded(Message msg) throws java.lang.Exception
msg
- the message object with fields to format
java.lang.Exception
public final byte[] formatPlain(Message msg) throws java.lang.Exception
msg
- the message object to be formattedjava.lang.Exception
public final byte[] formatLLPlain(Message msg) throws java.lang.Exception
msg
- the message object to be formattedjava.lang.Exception
public final byte[] formatLLLLPlain(Message msg) throws java.lang.Exception
msg
- the message object to be formattedjava.lang.Exception
public final Message parseStream(java.io.InputStream is) throws java.lang.Exception
is
- the inputsream to parse
java.lang.Exception
public final Message parsePacked(byte[] in) throws java.lang.Exception
in
- bytes to parse
java.lang.Exception
public final Message parsePacked(java.io.InputStream is) throws java.lang.Exception
is
-
java.lang.Exception
public final Message parseLLPlain(java.io.InputStream is) throws java.lang.Exception
is
- the inputstream
java.lang.Exception
public final Message parseLLLLPlain(java.io.InputStream is) throws java.lang.Exception
is
- inputstream
java.lang.Exception
public final Message parsePlain(byte[] buf) throws java.lang.Exception
buf
- - the byte buffer to parse
java.lang.Exception
public final Message parsePlain(java.io.InputStream is) throws java.lang.Exception
is
- - the inputstream
java.lang.Exception
public final void validateFields(Message flds) throws java.lang.Exception
flds
- - the message to validate
java.lang.Exception
- if not all fields validpublic final ISOField parsePlainField(java.io.DataInputStream dis, int i, int ver) throws java.lang.Exception
dis
- i
- - field numberver
- - the ISO8583 version (0, 1)
java.lang.Exception
public final byte[] createPackedValue(ISOField f)
public final byte[] createBinLenPackedValue(ISOField f)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |