public class FileResolverImpl extends Object implements FileResolver
BEAN_NAME| Constructor and Description |
|---|
FileResolverImpl() |
FileResolverImpl(boolean b) |
| Modifier and Type | Method and Description |
|---|---|
void |
addChangeLisenter(ChangeListener listener)
Deprecated.
|
void |
addChangeListener(ChangeListener listener)
添加文件变化监听器
|
void |
addFileProcessor(FileProcessor fileProcessor)
增加文件处理器
|
void |
addIncludePathPattern(String pattern)
手工添加扫描的匹配列表,如果有包含列表,则按包含列表
|
void |
addResolveFileObject(FileObject fileObject)
添加扫描的路径
|
void |
addResolvePath(List<String> paths)
添加扫描路径
|
void |
addResolvePath(String path)
添加扫描路径
|
void |
change()
文件变化触发的方法,会触发所有 ChangeListener
|
void |
config(XmlNode applicationConfig,
XmlNode componentConfig)
设置配置信息,应用配置和组件配置内容合并
|
XmlNode |
getApplicationConfig()
获取应用配置信息
|
String |
getApplicationNodePath()
获取在application.xml中配置对象的相对路径
|
List<ChangeListener> |
getChangeListeners()
返回所有的文件监听器列表
|
ClassLoader |
getClassLoader()
返回类加载器
|
XmlNode |
getComponentConfig()
获取组件配置信息
|
String |
getComponentConfigPath()
返回该配置对象组件配置的相对路径,相对于classpath的路径。
|
List<FileProcessor> |
getFileProcessorList()
返回所有的文件处理器
|
int |
getFileProcessorThreadNumber()
获取文件处理的线程数目
|
Map<String,Pattern> |
getIncludePathPatternMap()
返回所有的扫描路径正则
|
List<String> |
getScanningPaths()
返回当前FileResolver要扫描的根路径列表
|
void |
refresh()
刷新工作
|
void |
removeResolvePath(String path)
移除扫描路径
|
void |
resolve()
文件处理方法
|
void |
setChangeListeners(List<ChangeListener> changeListeners) |
void |
setClassLoader(ClassLoader classLoader)
设置类加载器
|
void |
setFileProcessorList(List<FileProcessor> fileProcessorList) |
void |
setFileProcessorThreadNumber(int threadNum)
设置文件处理的线程数目
|
public FileResolverImpl()
public FileResolverImpl(boolean b)
public List<ChangeListener> getChangeListeners()
FileResolvergetChangeListeners in interface FileResolverpublic void setChangeListeners(List<ChangeListener> changeListeners)
public List<String> getScanningPaths()
FileResolvergetScanningPaths in interface FileResolverpublic List<FileProcessor> getFileProcessorList()
FileResolvergetFileProcessorList in interface FileResolverpublic void setFileProcessorList(List<FileProcessor> fileProcessorList)
public void addFileProcessor(FileProcessor fileProcessor)
FileResolveraddFileProcessor in interface FileResolverfileProcessor - 文件处理器public ClassLoader getClassLoader()
FileResolvergetClassLoader in interface FileResolverpublic void setClassLoader(ClassLoader classLoader)
FileResolversetClassLoader in interface FileResolverclassLoader - 类加载器public void resolve()
FileResolverresolve in interface FileResolverpublic void addIncludePathPattern(String pattern)
FileResolveraddIncludePathPattern in interface FileResolverpattern - 扫描路径的正则public void addResolveFileObject(FileObject fileObject)
FileResolveraddResolveFileObject in interface FileResolverfileObject - 文件对象public void addResolvePath(String path)
FileResolveraddResolvePath in interface FileResolverpath - 扫描路径public void addResolvePath(List<String> paths)
FileResolveraddResolvePath in interface FileResolverpaths - 扫描路径列表public int getFileProcessorThreadNumber()
FileResolvergetFileProcessorThreadNumber in interface FileResolverpublic void setFileProcessorThreadNumber(int threadNum)
FileResolversetFileProcessorThreadNumber in interface FileResolverpublic void refresh()
refresh in interface FileResolverpublic String getApplicationNodePath()
ConfigurationgetApplicationNodePath in interface Configurationpublic String getComponentConfigPath()
ConfigurationgetComponentConfigPath in interface Configurationpublic void config(XmlNode applicationConfig, XmlNode componentConfig)
Configurationconfig in interface ConfigurationapplicationConfig - 应用配置节点componentConfig - 组件配置节点public XmlNode getComponentConfig()
ConfigurationgetComponentConfig in interface Configurationpublic XmlNode getApplicationConfig()
ConfigurationgetApplicationConfig in interface Configurationpublic Map<String,Pattern> getIncludePathPatternMap()
FileResolvergetIncludePathPatternMap in interface FileResolver@Deprecated public void addChangeLisenter(ChangeListener listener)
addChangeLisenter in interface FileResolverpublic void addChangeListener(ChangeListener listener)
FileResolveraddChangeListener in interface FileResolverpublic void change()
FileResolverchange in interface FileResolverpublic void removeResolvePath(String path)
FileResolverremoveResolvePath in interface FileResolverpath - 扫描路径Copyright © 2006–2018 TinyGroup. All rights reserved.