Package fmpp.dataloaders
Class SlicedTextDataLoader
java.lang.Object
fmpp.dataloaders.FileDataLoader
fmpp.dataloaders.AbstractTextDataLoader
fmpp.dataloaders.SlicedTextDataLoader
- All Implemented Interfaces:
DataLoader
Returns a sequence of strings based on a plain text file, where the specified
symbol is used as separator. For more information please read the FMPP
Manual.
-
Field Summary
Fields inherited from class fmpp.dataloaders.FileDataLoader
args, dataFile, engine
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected final String
parseExtraArguments
(List args) Parses the argument list, except the 1st (file name) argument.protected final Object
Parses the file content to the final object that the data loader will return.protected List
postProcessItems
(List items) Override this if you want to post-process the items.Methods inherited from class fmpp.dataloaders.AbstractTextDataLoader
load
Methods inherited from class fmpp.dataloaders.FileDataLoader
load
-
Constructor Details
-
SlicedTextDataLoader
public SlicedTextDataLoader()
-
-
Method Details
-
parseText
Description copied from class:AbstractTextDataLoader
Parses the file content to the final object that the data loader will return.- Specified by:
parseText
in classAbstractTextDataLoader
- Parameters:
text
- the content of the text file- Returns:
- the return value of the data loader
- Throws:
Exception
-
postProcessItems
Override this if you want to post-process the items.- Parameters:
items
- the list ofString
-s that the standard slicedText data loader would return.- Returns:
- the final return value of the custom data loader.
-
parseExtraArguments
Description copied from class:AbstractTextDataLoader
Parses the argument list, except the 1st (file name) argument.- Specified by:
parseExtraArguments
in classAbstractTextDataLoader
- Parameters:
args
- the arguments (all of them, starting from the 1st)- Returns:
- the encoding given with the extra arguments, or
null
if the encoding was not specified. In the latest case the encoding will default to the source encoding engine parameter (the sourceEncoding setting). - Throws:
Exception
-