com.raritantechnologies.xml.dataCollection
Class FTPXMLDataSource

java.lang.Object
  extended bycom.raritantechnologies.xml.dataCollection.FTPXMLDataSource
All Implemented Interfaces:
IConfigurable, IXMLDataSource

public class FTPXMLDataSource
extends java.lang.Object
implements IXMLDataSource

Implementation of IXMLDataSource that pulls files from an FTP host.

XML Configuration Template:
  <XMLSource class="com.raritantechnologies.xml.dataCollection.FTPXMLDataSource" 
                ftpHost="[ftp host URL]"
                userName="[ftp user name]"
                password="[the password]"
                remoteFilePath="/some/path"
                fileNamePattern="[reg expr pattern to match filenames]"
                includeSubdirectories="true/false"
                eventRecorderName="[name of IEventRecorder SystemObject]"
                eventName="[the name of this event]" >
 

Developed by Raritan Technologies .

Author:
Ted Sullivan

Constructor Summary
FTPXMLDataSource()
           
 
Method Summary
 java.lang.String getConfigurationXML()
           
 java.lang.String getEventName()
           
 IEventRecorder getEventRecorder()
           
 java.lang.String getFtpHost()
           
 org.w3c.dom.Document getNextResult()
          returns next available document
 java.lang.String getPassword()
           
 boolean getRecurseSubdirectories()
           
 java.lang.String getRemoteFilePath()
           
 java.lang.String getUserName()
           
 boolean hasMoreResults()
          returns true if more results available, false otherwise
 void init(RaritanPageContext rpc)
          Initialize the source.
 void initialize(org.w3c.dom.Element elem)
          Initializes the object from an XML tag or element.
 void setEventName(java.lang.String eventName)
           
 void setEventRecorder(IEventRecorder eRecorder)
           
 void setFtpHost(java.lang.String ftpHost)
           
 void setPassword(java.lang.String password)
           
 void setRecurseSubdirectories(boolean recurse)
           
 void setRemoteFilePath(java.lang.String remotePath)
           
 void setUserName(java.lang.String userName)
           
 void shutdown()
          close all connections, or other application resources.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FTPXMLDataSource

public FTPXMLDataSource()
Method Detail

init

public void init(RaritanPageContext rpc)
Description copied from interface: IXMLDataSource
Initialize the source. Points to the first available XML Result

Specified by:
init in interface IXMLDataSource

hasMoreResults

public boolean hasMoreResults()
Description copied from interface: IXMLDataSource
returns true if more results available, false otherwise

Specified by:
hasMoreResults in interface IXMLDataSource

getNextResult

public org.w3c.dom.Document getNextResult()
Description copied from interface: IXMLDataSource
returns next available document

Specified by:
getNextResult in interface IXMLDataSource

initialize

public void initialize(org.w3c.dom.Element elem)
Description copied from interface: IConfigurable
Initializes the object from an XML tag or element. This method is called by the Framework as part of the application initializtion. see ConfigurationManager, XMLConfigurationManager, XMLSearchFieldMapFactory, XMLSearchSourceFactory. Configurable objects that are owned or contained by other configurable objects will be initialized in by the parent object.

Specified by:
initialize in interface IConfigurable

shutdown

public void shutdown()
Description copied from interface: IXMLDataSource
close all connections, or other application resources.

Specified by:
shutdown in interface IXMLDataSource

setFtpHost

public void setFtpHost(java.lang.String ftpHost)

getFtpHost

public java.lang.String getFtpHost()

setUserName

public void setUserName(java.lang.String userName)

getUserName

public java.lang.String getUserName()

setPassword

public void setPassword(java.lang.String password)

getPassword

public java.lang.String getPassword()

setRemoteFilePath

public void setRemoteFilePath(java.lang.String remotePath)

getRemoteFilePath

public java.lang.String getRemoteFilePath()

setRecurseSubdirectories

public void setRecurseSubdirectories(boolean recurse)

getRecurseSubdirectories

public boolean getRecurseSubdirectories()

setEventRecorder

public void setEventRecorder(IEventRecorder eRecorder)

getEventRecorder

public IEventRecorder getEventRecorder()

setEventName

public void setEventName(java.lang.String eventName)

getEventName

public java.lang.String getEventName()

getConfigurationXML

public java.lang.String getConfigurationXML()