Class FileInboundChannelAdapterSpec
java.lang.Object
org.springframework.beans.factory.config.AbstractFactoryBean<T>
org.springframework.integration.dsl.IntegrationComponentSpec<S,H>
org.springframework.integration.dsl.MessageSourceSpec<FileInboundChannelAdapterSpec,FileReadingMessageSource>
org.springframework.integration.file.dsl.FileInboundChannelAdapterSpec
- All Implemented Interfaces:
- Aware,- BeanClassLoaderAware,- BeanFactoryAware,- DisposableBean,- FactoryBean<FileReadingMessageSource>,- InitializingBean,- Lifecycle,- Phased,- SmartLifecycle,- ComponentsRegistration
public class FileInboundChannelAdapterSpec extends MessageSourceSpec<FileInboundChannelAdapterSpec,FileReadingMessageSource> implements ComponentsRegistration
- Since:
- 5.0
- Author:
- Artem Bilan
- 
Field SummaryFields Modifier and Type Field Description protected FileListFilterFactoryBeanfileListFilterFactoryBeanFields inherited from class org.springframework.integration.dsl.IntegrationComponentSpecPARSER, target
- 
Constructor SummaryConstructors Modifier Constructor Description protectedFileInboundChannelAdapterSpec()protectedFileInboundChannelAdapterSpec(Comparator<File> receptionOrderComparator)
- 
Method SummaryMethods inherited from class org.springframework.integration.dsl.IntegrationComponentSpec_this, createInstance, destroyInstance, doGet, get, getId, getObjectType, getPhase, id, isAutoStartup, isRunning, start, stop, stopMethods inherited from class org.springframework.beans.factory.config.AbstractFactoryBeanafterPropertiesSet, destroy, getBeanFactory, getBeanTypeConverter, getEarlySingletonInterfaces, getObject, isSingleton, setBeanClassLoader, setBeanFactory, setSingleton
- 
Field Details
- 
Constructor Details- 
FileInboundChannelAdapterSpecprotected FileInboundChannelAdapterSpec()
- 
FileInboundChannelAdapterSpec
 
- 
- 
Method Details- 
recursiveA convenient flag to determine if target message source should use aRecursiveDirectoryScanneror stay with a default one.- Parameters:
- recursive- to set or not a- RecursiveDirectoryScanner.
- Returns:
- the spec.
- Since:
- 5.5
- See Also:
- RecursiveDirectoryScanner
 
- 
scannerSpecify a custom scanner.- Parameters:
- scanner- the scanner.
- Returns:
- the spec.
- See Also:
- FileReadingMessageSource.setScanner(DirectoryScanner)
 
- 
autoCreateDirectorySpecify whether to create the source directory automatically if it does not yet exist upon initialization. By default, this value istrue. If set tofalseand the source directory does not exist, an Exception will be thrown upon initialization.- Parameters:
- autoCreateDirectory- the autoCreateDirectory.
- Returns:
- the spec.
- See Also:
- FileReadingMessageSource.setAutoCreateDirectory(boolean)
 
- 
filterConfigure the filter.- Parameters:
- filter- the filter.
- Returns:
- the spec.
- See Also:
- FileReadingMessageSource.setFilter(FileListFilter)
 
- 
filterExpressionConfigure theExpressionFileListFilter.- Parameters:
- expression- the SpEL expression for files filtering.
- Returns:
- the spec.
- See Also:
- FileReadingMessageSource.setFilter(FileListFilter),- ExpressionFileListFilter
 
- 
filterFunctionConfigure theExpressionFileListFilter.- Parameters:
- filterFunction- the- Functionfor files filtering.
- Returns:
- the spec.
- See Also:
- FileReadingMessageSource.setFilter(FileListFilter),- ExpressionFileListFilter
 
- 
preventDuplicatesConfigure anAcceptOnceFileListFilterifpreventDuplicates == true, otherwise -AcceptAllFileListFilter.- Parameters:
- preventDuplicates- true to configure an- AcceptOnceFileListFilter.
- Returns:
- the spec.
 
- 
ignoreHiddenConfigure anIgnoreHiddenFileListFilterifignoreHidden == true.- Parameters:
- ignoreHidden- true to configure an- IgnoreHiddenFileListFilter.
- Returns:
- the spec.
 
- 
patternFilterConfigure aSimplePatternFileListFilter.- Parameters:
- pattern- The pattern.
- Returns:
- the spec.
- See Also:
- FileReadingMessageSource.setFilter(FileListFilter),- filter(FileListFilter)
 
- 
regexFilterConfigure aRegexPatternFileListFilter.- Parameters:
- regex- The regex.
- Returns:
- the spec.
- See Also:
- FileReadingMessageSource.setFilter(FileListFilter),- filter(FileListFilter)
 
- 
lockerSet aFileLockerto be used to guard files against duplicate processing.- Parameters:
- locker- the locker.
- Returns:
- the spec.
- See Also:
- FileReadingMessageSource.setLocker(FileLocker)
 
- 
nioLockerConfigure anNioFileLocker.- Returns:
- the spec.
- See Also:
- locker(FileLocker)
 
- 
scanEachPollSet this flag if you want to make sure the internal queue is refreshed with the latest content of the input directory on each poll.- Parameters:
- scanEachPoll- the scanEachPoll.
- Returns:
- the spec.
- See Also:
- FileReadingMessageSource.setScanEachPoll(boolean)
 
- 
useWatchServiceSwitch thisFileReadingMessageSourceto use its internalWatchServicedirectory scanner.- Parameters:
- useWatchService- the- booleanflag to enable the use of a- WatchService.
- Returns:
- the spec.
- See Also:
- watchEvents(org.springframework.integration.file.FileReadingMessageSource.WatchEventType...),- FileReadingMessageSource.setUseWatchService(boolean)
 
- 
watchEventspublic FileInboundChannelAdapterSpec watchEvents(FileReadingMessageSource.WatchEventType... watchEvents)- Parameters:
- watchEvents- the set of- FileReadingMessageSource.WatchEventType.
- Returns:
- the spec.
- See Also:
- useWatchService(boolean),- FileReadingMessageSource.setWatchEvents(org.springframework.integration.file.FileReadingMessageSource.WatchEventType...)
 
- 
getComponentsToRegister- Specified by:
- getComponentsToRegisterin interface- ComponentsRegistration
 
 
-