org.jpos.iso
Interface ISOChannel

All Superinterfaces:
ISOSource
All Known Subinterfaces:
ClientChannel, FilteredChannel, ServerChannel
All Known Implementing Classes:
AmexChannel, ASCIIChannel, BASE24Channel, BASE24TCPChannel, BaseChannel, BCDChannel, ChannelPool, CSChannel, FilteredBase, FSDChannel, GZIPChannel, HEXChannel, LogChannel, LoopbackChannel, NACChannel, NCCChannel, PADChannel, PostChannel, RawChannel, RBPChannel, TelnetXMLChannel, VAPChannel, X25Channel, XMLChannel

public interface ISOChannel
extends ISOSource

allows the transmision and reception of ISO 8583 Messages

Version:
$Revision$ $Date$
Author:
Alejandro P. Revilla, Alwyn Schoeman

Field Summary
static int CONNECT
           
static int RX
           
static int SIZEOF_CNT
           
static int TX
           
 
Method Summary
 Object clone()
          Expose channel clonning interface
 void connect()
          Connects ISOChannel
 void disconnect()
          disconnects ISOChannel
 String getName()
           
 ISOPackager getPackager()
           
 boolean isConnected()
           
 ISOMsg receive()
          Receives an ISOMsg
 void reconnect()
          Reconnect channel
 void send(byte[] b)
          sends a byte[] over the TCP/IP session
 void send(ISOMsg m)
          sends an ISOMsg over the TCP/IP session
 void setName(String name)
          associates this ISOChannel with a name on NameRegistrar
 void setPackager(ISOPackager p)
          Associate a packager with this channel
 void setUsable(boolean b)
           
 

Field Detail

CONNECT

static final int CONNECT
See Also:
Constant Field Values

TX

static final int TX
See Also:
Constant Field Values

RX

static final int RX
See Also:
Constant Field Values

SIZEOF_CNT

static final int SIZEOF_CNT
See Also:
Constant Field Values
Method Detail

setPackager

void setPackager(ISOPackager p)
Associate a packager with this channel

Parameters:
p - an ISOPackager

connect

void connect()
             throws IOException
Connects ISOChannel

Throws:
IOException

disconnect

void disconnect()
                throws IOException
disconnects ISOChannel

Throws:
IOException

reconnect

void reconnect()
               throws IOException
Reconnect channel

Throws:
IOException

isConnected

boolean isConnected()
Specified by:
isConnected in interface ISOSource
Returns:
true if Channel is connected and usable

receive

ISOMsg receive()
               throws IOException,
                      ISOException
Receives an ISOMsg

Returns:
the Message received
Throws:
IOException
ISOException

send

void send(ISOMsg m)
          throws IOException,
                 ISOException
sends an ISOMsg over the TCP/IP session

Specified by:
send in interface ISOSource
Parameters:
m - the Message to be sent
Throws:
IOException
ISOException

send

void send(byte[] b)
          throws IOException,
                 ISOException
sends a byte[] over the TCP/IP session

Parameters:
b - the byte array to be sent
Throws:
IOException
ISOException

setUsable

void setUsable(boolean b)
Parameters:
b - - usable state

setName

void setName(String name)
associates this ISOChannel with a name on NameRegistrar

Parameters:
name - name to register
See Also:
NameRegistrar

getName

String getName()
Returns:
this ISOChannel's name ("" if no name was set)

getPackager

ISOPackager getPackager()
Returns:
current packager

clone

Object clone()
Expose channel clonning interface



Copyright © 1998-2012 jPOS.org. All Rights Reserved.