org.apache.camel.component.file.remote
Class RemoteFileEndpoint<T>

java.lang.Object
  extended by org.apache.camel.impl.DefaultEndpoint
      extended by org.apache.camel.impl.ScheduledPollEndpoint
          extended by org.apache.camel.component.file.GenericFileEndpoint<T>
              extended by org.apache.camel.component.file.remote.RemoteFileEndpoint<T>
All Implemented Interfaces:
CamelContextAware, Endpoint, IsSingleton
Direct Known Subclasses:
FtpEndpoint, SftpEndpoint

public abstract class RemoteFileEndpoint<T>
extends GenericFileEndpoint<T>

Remote file endpoint.


Field Summary
 
Fields inherited from class org.apache.camel.component.file.GenericFileEndpoint
autoCreate, bufferSize, configuration, DEFAULT_IDEMPOTENT_CACHE_SIZE, DEFAULT_STRATEGYFACTORY_CLASS, delete, exclude, exclusiveReadLockStrategy, fileExist, fileName, filter, flatten, idempotent, idempotentRepository, include, inProgressRepository, localWorkDirectory, log, maxMessagesPerPoll, move, noop, preMove, processStrategy, readLock, readLockTimeout, recursive, sortBy, sorter, tempPrefix
 
Constructor Summary
RemoteFileEndpoint()
           
RemoteFileEndpoint(String uri, RemoteFileComponent<T> component, RemoteFileConfiguration configuration)
           
 
Method Summary
protected  void afterPropertiesSet()
          Validates this endpoint if its configured properly.
protected abstract  RemoteFileConsumer<T> buildConsumer(Processor processor)
          Remote File Endpoints, impl this method to create a custom consumer specific to their "protocol" etc.
protected abstract  GenericFileProducer<T> buildProducer()
          Remote File Endpoints, impl this method to create a custom producer specific to their "protocol" etc.
 RemoteFileConsumer<T> createConsumer(Processor processor)
           
 GenericFileExchange createExchange()
           
 GenericFileExchange<T> createExchange(GenericFile<T> file)
           
 GenericFileProducer<T> createProducer()
           
 char getFileSeparator()
           
 boolean isAbsolute(String name)
           
 String remoteServerInformation()
          Returns human readable server information for logging purpose
 
Methods inherited from class org.apache.camel.component.file.GenericFileEndpoint
configureMessage, configureMoveOrPreMoveExpression, createGenericFileStrategy, getBufferSize, getConfiguration, getExclude, getExclusiveReadLockStrategy, getFileExist, getFileName, getFilter, getGeneratedFileName, getGenericFileProcessStrategy, getIdempotentRepository, getInclude, getInProgressRepository, getLocalWorkDirectory, getMaxMessagesPerPoll, getMove, getParamsAsMap, getPreMove, getProcessStrategy, getReadLock, getReadLockTimeout, getScheme, getSortBy, getSorter, getTempPrefix, isAutoCreate, isDelete, isFlatten, isIdempotent, isNoop, isRecursive, isSingleton, setAutoCreate, setBufferSize, setConfiguration, setDelete, setExclude, setExclusiveReadLockStrategy, setFileExist, setFileName, setFileName, setFilter, setFlatten, setGenericFileProcessStrategy, setIdempotent, setIdempotentRepository, setInclude, setInProgressRepository, setLocalWorkDirectory, setMaxMessagesPerPoll, setMove, setMove, setNoop, setPreMove, setPreMove, setProcessStrategy, setReadLock, setReadLockTimeout, setRecursive, setSortBy, setSortBy, setSortBy, setSorter, setTempPrefix
 
Methods inherited from class org.apache.camel.impl.ScheduledPollEndpoint
configureConsumer, configureProperties, getConsumerProperties, setConsumerProperties
 
Methods inherited from class org.apache.camel.impl.DefaultEndpoint
convertTo, createEndpointUri, createExchange, createExchange, createPollingConsumer, createScheduledExecutorService, equals, getCamelContext, getComponent, getEndpointUri, getExchangePattern, getExchangeType, getExecutorService, getScheduledExecutorService, hashCode, isLenientProperties, setCamelContext, setEndpointUri, setEndpointUriIfNotSpecified, setExchangePattern, setExecutorService, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RemoteFileEndpoint

public RemoteFileEndpoint()

RemoteFileEndpoint

public RemoteFileEndpoint(String uri,
                          RemoteFileComponent<T> component,
                          RemoteFileConfiguration configuration)
Method Detail

createExchange

public GenericFileExchange createExchange()
Specified by:
createExchange in interface Endpoint
Overrides:
createExchange in class DefaultEndpoint

createExchange

public GenericFileExchange<T> createExchange(GenericFile<T> file)
Specified by:
createExchange in class GenericFileEndpoint<T>

createProducer

public GenericFileProducer<T> createProducer()
                                      throws Exception
Specified by:
createProducer in interface Endpoint
Overrides:
createProducer in class GenericFileEndpoint<T>
Throws:
Exception

createConsumer

public RemoteFileConsumer<T> createConsumer(Processor processor)
                                     throws Exception
Specified by:
createConsumer in interface Endpoint
Overrides:
createConsumer in class GenericFileEndpoint<T>
Throws:
Exception

afterPropertiesSet

protected void afterPropertiesSet()
                           throws Exception
Validates this endpoint if its configured properly.

Throws:
Exception - is thrown if endpoint is invalid configured for its mandatory options

buildConsumer

protected abstract RemoteFileConsumer<T> buildConsumer(Processor processor)
Remote File Endpoints, impl this method to create a custom consumer specific to their "protocol" etc.

Parameters:
processor - the processor
Returns:
the created consumer

buildProducer

protected abstract GenericFileProducer<T> buildProducer()
Remote File Endpoints, impl this method to create a custom producer specific to their "protocol" etc.

Returns:
the created producer

remoteServerInformation

public String remoteServerInformation()
Returns human readable server information for logging purpose


getFileSeparator

public char getFileSeparator()
Specified by:
getFileSeparator in class GenericFileEndpoint<T>

isAbsolute

public boolean isAbsolute(String name)
Specified by:
isAbsolute in class GenericFileEndpoint<T>


Copyright © 2009 Apache Software Foundation. All Rights Reserved.