Package net.n2oapp.framework.config.util
Class FileSystemUtil
java.lang.Object
net.n2oapp.framework.config.util.FileSystemUtil
- Since:
- 15.04.2015
- Author:
- operehod
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringgetContent(Node node) static InputStreamgetContentAsStream(String path) static InputStreamgetContentAsStream(String path, boolean isExistRequired) static StringgetContentByUri(String uri) static StringgetContentByUri(String uri, boolean isExistRequired) static StringgetContentFromResource(org.springframework.core.io.Resource resource) static longgetFileSizeByUri(String uri) static NodegetNodesByLocationPattern(String locationPattern) getNodesByLocationPattern(String locationPattern, Predicate<String> nameFilter) getNodesByLocationPattern(List<String> locationPattern) static voidremoveAllFromDirectory(String dir, List<String> excludePaths) static BooleanremoveContentByUri(String uri) static voidsaveContentToFile(InputStream content, File file) static voidsaveContentToFile(String content, File file)
-
Field Details
-
FILE_NAME_WITHOUT_DOTS
-
-
Constructor Details
-
FileSystemUtil
public FileSystemUtil()
-
-
Method Details
-
saveContentToFile
-
saveContentToFile
-
removeContentByUri
-
getNodesByLocationPattern
-
getNodesByLocationPattern
-
getNodeByClasspathUri
-
getNodesByLocationPattern
-
getContent
-
getContentByUri
-
getContentByUri
-
getContentAsStream
- Throws:
IOException
-
getContentAsStream
public static InputStream getContentAsStream(String path, boolean isExistRequired) throws IOException - Throws:
IOException
-
getContentFromResource
-
removeAllFromDirectory
-
getFileSizeByUri
- Throws:
IOException
-