Package echo.util
Class FindFileInClassPath
- java.lang.Object
-
- echo.util.FindFileInClassPath
-
class FindFileInClassPath extends java.lang.ObjectTry to retrieve content from the java class path. Usually placed under src/main/resources
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.StringabsoluteFilePathprivate java.io.InputStreaminputStreamprivate PluginLogmavenPluginLog
-
Constructor Summary
Constructors Constructor Description FindFileInClassPath(PluginLog mavenPluginLog)Creates a new instance of the class
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetAbsoluteFilePath()java.io.InputStreamgetInputStream()Return stream to file contentbooleanisFound()Return true if stream is opened to file contentvoidopenFile(java.lang.String fileName)Try to open a stream to the file location in the class path
-
-
-
Field Detail
-
mavenPluginLog
private final PluginLog mavenPluginLog
-
inputStream
private java.io.InputStream inputStream
-
absoluteFilePath
private java.lang.String absoluteFilePath
-
-
Constructor Detail
-
FindFileInClassPath
public FindFileInClassPath(PluginLog mavenPluginLog)
Creates a new instance of the class- Parameters:
mavenPluginLog- Wrapper for Maven internal plugin logger
-
-
Method Detail
-
openFile
public void openFile(java.lang.String fileName)
Try to open a stream to the file location in the class path
-
isFound
public boolean isFound()
Return true if stream is opened to file content
-
getInputStream
public java.io.InputStream getInputStream()
Return stream to file content
-
getAbsoluteFilePath
public java.lang.String getAbsoluteFilePath()
-
-