public class FileResourceManager extends Object
Constructor and Description |
---|
FileResourceManager() |
Modifier and Type | Method and Description |
---|---|
boolean |
addResource(String path,
FileObject file)
添加文件资源
|
void |
addResources(TemplateEngine engine,
FileObject root,
String templateExtName,
String layoutExtName,
String componentExtName)
批量增加某个VFS路径下的模板引擎相关资源
|
void |
addResources(TemplateEngine engine,
FileObject root,
String templateExtName,
String layoutExtName,
String componentExtName,
boolean logTag)
批量增加某个VFS路径下的模板引擎相关资源
|
void |
addResources(TemplateEngine engine,
String resource,
String templateExtName,
String layoutExtName,
String componentExtName)
批量增加某个VFS路径下的模板引擎相关资源
|
void |
addScanFile(FileObject file) |
FileObject |
getFileObject(String path)
查询已经注册文件资源
|
FileObject |
getFileObject(String path,
boolean tag)
查询已经注册文件资源
|
FileResolver |
getFileResolver() |
FileObject |
getOtherFileObject(String path)
查询注册模板资源以外的其他文件
|
boolean |
isModified(String path)
文件是否被修改
|
boolean |
isModified(String path,
boolean tag)
文件是否被修改
|
boolean |
isTextOrderByTime() |
void |
removeResource(FileObject file)
删除文件资源
|
void |
removeResources(TemplateEngine engine,
FileObject root,
String templateExtName,
String layoutExtName,
String componentExtName)
批量删除某个VFS路径下的模板引擎相关资源
|
void |
removeResources(TemplateEngine engine,
String resource,
String templateExtName,
String layoutExtName,
String componentExtName)
批量删除某个VFS路径下的模板引擎相关资源
|
void |
removeScanFile(FileObject file) |
void |
resetModified(String path)
重置文件修改标识
|
void |
resetModified(String path,
boolean tag)
重置文件修改标识
|
void |
setFileResolver(FileResolver fileResolver) |
void |
setTextOrderByTime(boolean textOrderByTime) |
protected static final Logger LOGGER
public boolean isTextOrderByTime()
public void setTextOrderByTime(boolean textOrderByTime)
public FileResolver getFileResolver()
public void setFileResolver(FileResolver fileResolver)
public void addScanFile(FileObject file)
public void addResources(TemplateEngine engine, FileObject root, String templateExtName, String layoutExtName, String componentExtName)
engine
- root
- templateExtName
- layoutExtName
- componentExtName
- public void addResources(TemplateEngine engine, FileObject root, String templateExtName, String layoutExtName, String componentExtName, boolean logTag)
engine
- root
- templateExtName
- layoutExtName
- componentExtName
- logTag
- public void addResources(TemplateEngine engine, String resource, String templateExtName, String layoutExtName, String componentExtName)
engine
- resource
- templateExtName
- layoutExtName
- componentExtName
- public boolean addResource(String path, FileObject file)
path
- file
- public void removeScanFile(FileObject file)
public void removeResources(TemplateEngine engine, FileObject root, String templateExtName, String layoutExtName, String componentExtName)
engine
- root
- templateExtName
- layoutExtName
- componentExtName
- public void removeResources(TemplateEngine engine, String resource, String templateExtName, String layoutExtName, String componentExtName)
engine
- resource
- templateExtName
- layoutExtName
- componentExtName
- public void removeResource(FileObject file)
file
- public FileObject getFileObject(String path, boolean tag)
path
- tag
- 是否精确匹配public FileObject getFileObject(String path)
path
- public FileObject getOtherFileObject(String path)
path
- public boolean isModified(String path)
path
- public boolean isModified(String path, boolean tag)
path
- public void resetModified(String path)
path
- public void resetModified(String path, boolean tag)
path
- Copyright © 2006–2018 TinyGroup. All rights reserved.