org.fossilec.odettej.service
Class Service

java.lang.Object
  extended by org.fossilec.odettej.service.Service
Direct Known Subclasses:
StreamTransmissionService, UsualService

public abstract class Service
extends java.lang.Object

Author:
Rafael Marins

Constructor Summary
protected Service(Transport transport, int debSize)
          Class constructor used with a given transport implementation which should be used instead of creating a new one.
 
Method Summary
 boolean connect(java.lang.String address)
           
 void disconnect()
           
protected  int getExchangeBufferSize()
           
static Service getInstance(Transport transport, int debSize, boolean useStreamTransmissionBuffer)
           
 Transport getTransport()
           
 boolean isConnected()
           
abstract  OdetteExchangeBuffer receive(boolean strictFormat)
           
abstract  int send(OdetteExchangeBuffer oeb)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Service

protected Service(Transport transport,
                  int debSize)
Class constructor used with a given transport implementation which should be used instead of creating a new one. This constructor is almost used when working as the Responder with this API.

Parameters:
transport - Transport implementation used by the service layer.
Throws:
OdetteFTPException
java.lang.IllegalArgumentException - If the properties argument is null.
See Also:
Session, Transport
Method Detail

connect

public boolean connect(java.lang.String address)
                throws OdetteFTPException
Throws:
OdetteFTPException

disconnect

public void disconnect()
                throws OdetteFTPException
Throws:
OdetteFTPException

getExchangeBufferSize

protected int getExchangeBufferSize()

getTransport

public Transport getTransport()
                       throws OdetteFTPException
Throws:
OdetteFTPException

isConnected

public boolean isConnected()
                    throws OdetteFTPException
Throws:
OdetteFTPException

receive

public abstract OdetteExchangeBuffer receive(boolean strictFormat)
                                      throws OdetteFTPException
Throws:
OdetteFTPException

send

public abstract int send(OdetteExchangeBuffer oeb)
                  throws OdetteFTPException
Throws:
OdetteFTPException

getInstance

public static Service getInstance(Transport transport,
                                  int debSize,
                                  boolean useStreamTransmissionBuffer)


Copyright © 2005 ObjectWeb Consortium. All Rights Reserved.