public class ProblemFactory
extends java.lang.Object
CodedProblem
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_TRACE_LEVEL
The default trace level.
|
Constructor and Description |
---|
ProblemFactory()
Creates a new problem factory.
|
Modifier and Type | Method and Description |
---|---|
CodedProblem |
encode()
Encodes and instantiates the planning problem.
|
static ProblemFactory |
getInstance()
Returns an instance of this class.
|
int |
getTraceLevel()
Returns the trace level.
|
ErrorManager |
parse(java.io.File domain,
java.io.File problem)
Parses the domain and the problem description.
|
ErrorManager |
parse(java.lang.String domain,
java.lang.String problem)
Parses the domain and the problem description.
|
ErrorManager |
parseFromString(java.lang.String domain,
java.lang.String problem)
Parses the domain and the problem description.
|
void |
setTraceLevel(int level)
Sets the trace level.
|
public static final int DEFAULT_TRACE_LEVEL
public static ProblemFactory getInstance()
public ErrorManager parse(java.io.File domain, java.io.File problem) throws java.io.IOException
domain
- the domain file.problem
- the problem filejava.io.FileNotFoundException
- if the domain or the problem file was not found.java.io.IOException
- if an error occur during parsing.public ErrorManager parse(java.lang.String domain, java.lang.String problem) throws java.io.IOException
domain
- the domain file path.problem
- the problem file path.java.io.FileNotFoundException
- if the domain or the problem file was not found.java.io.IOException
- if an error occur during parsing.public ErrorManager parseFromString(java.lang.String domain, java.lang.String problem) throws java.io.IOException
domain
- the domain string descriptionproblem
- the problem string descriptionjava.io.IOException
- if an error occur during parsingpublic CodedProblem encode()
public final void setTraceLevel(int level)
level
- the trace level.public final int getTraceLevel()