jPOS 1.6.1 API Documentation

org.jpos.iso.header
Class BASE1Header

java.lang.Object
  extended by org.jpos.iso.header.BaseHeader
      extended by org.jpos.iso.header.BASE1Header
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, ISOHeader, Loggeable

public class BASE1Header
extends BaseHeader

See Also:
Serialized Form

Field Summary
static int LENGTH
           
 
Constructor Summary
BASE1Header()
           
BASE1Header(byte[] header)
           
BASE1Header(java.lang.String source, java.lang.String destination)
           
 
Method Summary
 java.lang.String getDestination()
          Return the destination address in this ISOHeader.
 int getFormat()
           
 int getHLen()
           
 java.lang.String getRejectCode()
          Gets the BASE 1 Reject Code.
 java.lang.String getSource()
          Return the source address in this ISOHeader.
 boolean isRejected()
           
 void setBatchNumber(int i)
           
 void setDestination(java.lang.String dest)
          Set the Destination address in this ISOHeader.
 void setFlags(int i)
           
 void setFormat(int format)
           
 void setHFormat(int hformat)
           
 void setLen(int len)
           
 void setRtCtl(int i)
           
 void setSource(java.lang.String src)
          Set the Source address in this ISOHeader.
 void setStatus(int i)
           
 void swapDirection()
          Swap the source and destination addresses in this ISOHeader (if they exist).
 int unpack(byte[] header)
          Create a new ISOHeader from a byte array.
 
Methods inherited from class org.jpos.iso.header.BaseHeader
clone, dump, getLength, pack
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LENGTH

public static final int LENGTH
See Also:
Constant Field Values
Constructor Detail

BASE1Header

public BASE1Header()

BASE1Header

public BASE1Header(java.lang.String source,
                   java.lang.String destination)

BASE1Header

public BASE1Header(byte[] header)
Method Detail

unpack

public int unpack(byte[] header)
Description copied from interface: ISOHeader
Create a new ISOHeader from a byte array.

Specified by:
unpack in interface ISOHeader
Overrides:
unpack in class BaseHeader
Returns:
The Number of bytes consumed.

getHLen

public int getHLen()

setHFormat

public void setHFormat(int hformat)

getFormat

public int getFormat()

setRtCtl

public void setRtCtl(int i)

setFlags

public void setFlags(int i)

setStatus

public void setStatus(int i)

setBatchNumber

public void setBatchNumber(int i)

setFormat

public void setFormat(int format)

setLen

public void setLen(int len)

setDestination

public void setDestination(java.lang.String dest)
Description copied from interface: ISOHeader
Set the Destination address in this ISOHeader.

Specified by:
setDestination in interface ISOHeader
Overrides:
setDestination in class BaseHeader

setSource

public void setSource(java.lang.String src)
Description copied from interface: ISOHeader
Set the Source address in this ISOHeader.

Specified by:
setSource in interface ISOHeader
Overrides:
setSource in class BaseHeader

getSource

public java.lang.String getSource()
Description copied from interface: ISOHeader
Return the source address in this ISOHeader. returns null if there is no source address

Specified by:
getSource in interface ISOHeader
Overrides:
getSource in class BaseHeader

getDestination

public java.lang.String getDestination()
Description copied from interface: ISOHeader
Return the destination address in this ISOHeader. returns null if there is no destination address

Specified by:
getDestination in interface ISOHeader
Overrides:
getDestination in class BaseHeader

swapDirection

public void swapDirection()
Description copied from interface: ISOHeader
Swap the source and destination addresses in this ISOHeader (if they exist).

Specified by:
swapDirection in interface ISOHeader
Overrides:
swapDirection in class BaseHeader

isRejected

public boolean isRejected()

getRejectCode

public java.lang.String getRejectCode()
Gets the BASE 1 Reject Code.

Returns:
If the message is a reject return the Reject Code Otherwise return ""

jPOS.org