Package net.andreinc.mockneat.utils.file
Class FileManager
java.lang.Object
net.andreinc.mockneat.utils.file.FileManager
public class FileManager
extends java.lang.Object
-
Constructor Summary
Constructors Constructor Description FileManager() -
Method Summary
Modifier and Type Method Description static FileManagergetInstance()java.util.List<java.lang.String>getLines(java.lang.String path)This method returns the cached lines for the file.java.util.List<java.lang.String>getLines(DictType dictType)java.util.Set<java.lang.String>getUniqueLines(DictType dictType)java.util.List<java.lang.String>read(java.lang.String key)java.util.List<java.lang.String>read(DictType dictType)java.util.List<java.lang.String>read(MarkovChainType markovChainType)
-
Constructor Details
-
FileManager
public FileManager()
-
-
Method Details
-
getInstance
-
getLines
public java.util.List<java.lang.String> getLines(java.lang.String path)This method returns the cached lines for the file.- Parameters:
path- The path to the file.- Returns:
- A string containing all the lines from path (cached).
-
getLines
-
getUniqueLines
-
read
public java.util.List<java.lang.String> read(MarkovChainType markovChainType) throws java.io.IOException- Throws:
java.io.IOException
-
read
- Throws:
java.io.IOException
-
read
public java.util.List<java.lang.String> read(java.lang.String key) throws java.io.IOException- Throws:
java.io.IOException
-