public abstract class AbstractOperationLoader extends Object implements OperationLoader
Constructor and Description |
---|
AbstractOperationLoader() |
Modifier and Type | Method and Description |
---|---|
protected InputStream |
getInputStream(File baseDir,
String filename)
Gets an input stream for the given file
|
static OperationLoaderArgument |
getNameArgument(boolean optional)
Gets the standard argument for the friendly name
|
protected String |
readFile(File baseDir,
String filename)
Try to read in a given file as UTF-8 content
|
protected File |
resolveFile(File baseDir,
String filename)
Resolves a file to see if it a valid file that exists either on disk or
in the class path
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getArguments, getDescription, getPreferredName, load
protected String readFile(File baseDir, String filename) throws FileNotFoundException, IOException
baseDir
- Base directoryfilename
- FilenameFileNotFoundException
IOException
protected InputStream getInputStream(File baseDir, String filename) throws FileNotFoundException, IOException
baseDir
- Base directoryfilename
- FilenameFileNotFoundException
IOException
protected File resolveFile(File baseDir, String filename) throws FileNotFoundException
file
- File to resolveFileNotFoundException
- Thrown if the file cannot be resolvedpublic static OperationLoaderArgument getNameArgument(boolean optional)
optional
- Whether the friendly name is optionalCopyright © 2015. All rights reserved.