Constructor and Description |
---|
FileSource(String baseTemplatePath,
String fileName) |
FileSource(String baseTemplatePath,
String fileName,
String encoding) |
Modifier and Type | Method and Description |
---|---|
StringBuilder |
getContent()
content of ISource
|
String |
getEncoding()
encoding of content
|
String |
getFileName() |
String |
getFinalFileName() |
String |
getKey()
key used to cache, return null if do not cache the template
注意:如果不希望缓存从该 ISource 解析出来的 Template 对象
让 getKey() 返回 null 值即可
|
boolean |
isModified()
reload template if modified on devMode
|
static StringBuilder |
loadFile(File file,
String encoding) |
String |
toString() |
public boolean isModified()
ISource
isModified
in interface ISource
public String getKey()
ISource
public String getEncoding()
ISource
getEncoding
in interface ISource
public String getFinalFileName()
public String getFileName()
public StringBuilder getContent()
ISource
getContent
in interface ISource
public static StringBuilder loadFile(File file, String encoding)
Copyright © 2018. All rights reserved.