Package org.nuiton.eugene
Class ModelReader<M extends Model>
- java.lang.Object
-
- org.nuiton.eugene.ModelReader<M>
-
- Type Parameters:
M- Model to create from reading input files
- Direct Known Subclasses:
AbstractObjectModelReader,StateModelReader
public abstract class ModelReader<M extends Model> extends Object
ModelReader TODO real doc :) Created: 26 oct. 2009- Author:
- Florian Desbois - desbois@codelutin.com
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanstrictLoadingA flag to load only safe things.protected TagValueMetadatasProvidertagValueMetadatasProviderProvider of tag values.protected booleanverboseA verbose flag to see more things.
-
Constructor Summary
Constructors Constructor Description ModelReader()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract StringgetInputType()Gets the type of input file.abstract StringgetModelType()Gets the type of model.booleanisStrictLoading()booleanisVerbose()abstract Mread(File... file)Read files to produce a memory model.voidsetStrictLoading(boolean strictLoading)voidsetVerbose(boolean verbose)
-
-
-
Field Detail
-
verbose
protected boolean verbose
A verbose flag to see more things.- Since:
- 2.3
-
strictLoading
protected boolean strictLoading
A flag to load only safe things. Usefull to have a safe loading of a model and his properties file.- Since:
- 2.3
-
tagValueMetadatasProvider
protected TagValueMetadatasProvider tagValueMetadatasProvider
Provider of tag values.- Since:
- 2.9
-
-
Method Detail
-
getModelType
public abstract String getModelType()
Gets the type of model.- Returns:
- the type of model.
- Since:
- 2.6.3
- See Also:
ModelHelper.ModelType
-
getInputType
public abstract String getInputType()
Gets the type of input file. For examplexml, oryaml.- Returns:
- the type of input file.
- Since:
- 2.6.3
-
isVerbose
public boolean isVerbose()
-
setVerbose
public void setVerbose(boolean verbose)
-
isStrictLoading
public boolean isStrictLoading()
-
setStrictLoading
public void setStrictLoading(boolean strictLoading)
-
read
public abstract M read(File... file) throws IOException
Read files to produce a memory model.- Parameters:
file- files to read- Returns:
- the new model builded from files
- Throws:
IOException- if any IO errors while reading files
-
-