org.apache.camel.component.file
Class FileConsumer
java.lang.Object
org.apache.camel.impl.ServiceSupport
org.apache.camel.impl.DefaultConsumer
org.apache.camel.impl.ScheduledPollConsumer
org.apache.camel.component.file.GenericFileConsumer<File>
org.apache.camel.component.file.FileConsumer
- All Implemented Interfaces:
- Runnable, BatchConsumer, Consumer, Service, ShutdownAware, SuspendableService
public class FileConsumer
- extends GenericFileConsumer<File>
File consumer.
| Methods inherited from class org.apache.camel.component.file.GenericFileConsumer |
deferShutdown, doStart, getPendingExchangesSize, isBatchAllowed, isInProgress, isMatched, isValidFile, poll, postPollCheck, prePollCheck, processBatch, processExchange, setMaxMessagesPerPoll |
| Methods inherited from class org.apache.camel.impl.ScheduledPollConsumer |
doStop, getDelay, getInitialDelay, getPollStrategy, getTimeUnit, isPollAllowed, isSuspended, isUseFixedDelay, resume, run, setDelay, setInitialDelay, setPollStrategy, setTimeUnit, setUseFixedDelay, suspend |
| Methods inherited from class org.apache.camel.impl.ServiceSupport |
addChildService, getStatus, getVersion, isRunAllowed, isStarted, isStarting, isStopped, isStopping, removeChildService, start, stop |
FileConsumer
public FileConsumer(GenericFileEndpoint<File> endpoint,
Processor processor,
GenericFileOperations<File> operations)
pollDirectory
protected void pollDirectory(String fileName,
List<GenericFile<File>> fileList)
- Description copied from class:
GenericFileConsumer
- Polls the given directory for files to process
- Specified by:
pollDirectory in class GenericFileConsumer<File>
- Parameters:
fileName - current directory or filefileList - current list of files gathered
asGenericFile
public static GenericFile<File> asGenericFile(String endpointPath,
File file)
- Creates a new GenericFile based on the given file.
- Parameters:
endpointPath - the starting directory the endpoint was configured withfile - the source file
- Returns:
- wrapped as a GenericFile
Copyright © 2007-2010 The Apache Software Foundation. All Rights Reserved.