Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.yaftp.ftp
Class FtpVectorListener  view FtpVectorListener download FtpVectorListener.java

java.lang.Object
  extended bycom.yaftp.ftp.FtpStandardListener
      extended bycom.yaftp.ftp.FtpVectorListener
All Implemented Interfaces:
FtpClientListener

public class FtpVectorListener
extends FtpStandardListener

provide a standard String vector for incoming String DataList

Version:
: 0.0.1

Field Summary
private static java.lang.String _CRLF_
          rfc 765 indicates that a CRLF should be sent as a end of line combination should be used where necessary to denote the end of a line
private  java.util.Vector _dataList
           
private  java.io.BufferedReader _localReader
           
private  java.io.BufferedWriter _localWriter
           
 
Fields inherited from class com.yaftp.ftp.FtpStandardListener
_listener
 
Constructor Summary
FtpVectorListener()
           
 
Method Summary
 void buildLocalReader(java.io.File file)
          call this method whenever you want to ftp PUT from a local file rather than by buffer when a _localReader has been built the writeData will be read from _localReader rather than from _dataList
 void buildLocalWriter(java.io.File file)
          call this method whenever you want to ftp GET intro a local file rather than by buffer when a _localReader has been built the writeData will be read from _localReader rather than from _dataList
 void closeLocalReader()
           
 void closeLocalWriter()
           
 java.util.Vector get_dataList()
           
 void readData(java.io.BufferedInputStream myStream, FtpDataNotifier dataEvt)
          unused
 void readData(java.io.InputStream myStream, FtpDataNotifier dataEvt)
           
 void set_dataList(java.util.Vector data)
          the data byte buffer should be set before the writeDataMethod is activated
 java.lang.String toString()
          if _dataList is not null return a concatenated String lines
 void writeData(java.io.BufferedOutputStream myWriter, FtpDataNotifier dataEvt)
          unused
 void writeData(java.io.OutputStream myStream, FtpDataNotifier dataEvt)
           
private  void writeFromBuffer(java.io.OutputStream myStream, FtpDataNotifier dataEvt)
           
private  void writeFromFile(java.io.OutputStream myStream, FtpDataNotifier dataEvt)
           
 
Methods inherited from class com.yaftp.ftp.FtpStandardListener
addFtpBufferTransfertListener, broadcastBufferEvent, dataError, get_dataMessage, removeFtpBufferTransfertListener, set_dataMessage
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_CRLF_

private static final java.lang.String _CRLF_
rfc 765 indicates that a CRLF should be sent as a end of line combination should be used where necessary to denote the end of a line

See Also:
Constant Field Values

_dataList

private java.util.Vector _dataList

_localWriter

private java.io.BufferedWriter _localWriter

_localReader

private java.io.BufferedReader _localReader
Constructor Detail

FtpVectorListener

public FtpVectorListener()
Method Detail

buildLocalReader

public void buildLocalReader(java.io.File file)
                      throws ClientFtpError
call this method whenever you want to ftp PUT from a local file rather than by buffer when a _localReader has been built the writeData will be read from _localReader rather than from _dataList

Specified by:
buildLocalReader in class FtpStandardListener

closeLocalReader

public void closeLocalReader()
                      throws ClientFtpError
Specified by:
closeLocalReader in class FtpStandardListener

buildLocalWriter

public void buildLocalWriter(java.io.File file)
                      throws ClientFtpError
call this method whenever you want to ftp GET intro a local file rather than by buffer when a _localReader has been built the writeData will be read from _localReader rather than from _dataList

Specified by:
buildLocalWriter in class FtpStandardListener

closeLocalWriter

public void closeLocalWriter()
                      throws ClientFtpError
Specified by:
closeLocalWriter in class FtpStandardListener

readData

public void readData(java.io.InputStream myStream,
                     FtpDataNotifier dataEvt)
Specified by:
readData in interface FtpClientListener
Specified by:
readData in class FtpStandardListener

writeFromBuffer

private void writeFromBuffer(java.io.OutputStream myStream,
                             FtpDataNotifier dataEvt)

writeFromFile

private void writeFromFile(java.io.OutputStream myStream,
                           FtpDataNotifier dataEvt)

writeData

public void writeData(java.io.OutputStream myStream,
                      FtpDataNotifier dataEvt)
Specified by:
writeData in interface FtpClientListener
Specified by:
writeData in class FtpStandardListener

readData

public void readData(java.io.BufferedInputStream myStream,
                     FtpDataNotifier dataEvt)
unused


writeData

public void writeData(java.io.BufferedOutputStream myWriter,
                      FtpDataNotifier dataEvt)
unused


get_dataList

public java.util.Vector get_dataList()

set_dataList

public void set_dataList(java.util.Vector data)
the data byte buffer should be set before the writeDataMethod is activated


toString

public java.lang.String toString()
if _dataList is not null return a concatenated String lines