Package org.opt4j.common.logger
Class LoggerModule
- java.lang.Object
-
- com.google.inject.AbstractModule
-
- org.opt4j.start.Opt4JModule
-
- org.opt4j.viewer.VisualizationModule
-
- org.opt4j.common.logger.LoggerModule
-
- All Implemented Interfaces:
com.google.inject.Module
public class LoggerModule extends VisualizationModule
Module for logging.- See Also:
Logger
-
-
Field Summary
Fields Modifier and Type Field Description protected int
evaluationStep
protected String
filename
protected int
iterationStep
protected boolean
loggingPerEvaluation
protected boolean
loggingPerIteration
-
Fields inherited from class org.opt4j.start.Opt4JModule
SINGLETON
-
-
Constructor Summary
Constructors Constructor Description LoggerModule()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
config()
Configure the module.int
getEvaluationStep()
Returns the step size of the evaluations.String
getFilename()
Returns the filename.int
getIterationStep()
Returns the step size of the iterations.boolean
isLoggingPerEvaluation()
Returnstrue
if the logger observes the number of evaluations.boolean
isLoggingPerIteration()
Returnstrue
if the logger observes the number of iterations.void
setEvaluationStep(int evaluationStep)
Sets the step size of the evaluations.void
setFilename(String filename)
Sets the filename.void
setIterationStep(int iterationStep)
Sets the step size of the iterations.void
setLoggingPerEvaluation(boolean loggingPerEvaluation)
Sets the observation for the number of evaluations.void
setLoggingPerIteration(boolean loggingPerIteration)
Sets the observation for the number of iterations.-
Methods inherited from class org.opt4j.viewer.VisualizationModule
addIndividualMouseListener, addIndividualMouseListener, addToolBarService, addToolBarService
-
Methods inherited from class org.opt4j.start.Opt4JModule
addControlListener, addIndividualStateListener, addOptimizerIterationListener, addOptimizerStateListener, bindConstant, bindConstant, bindConstant, bindConstant, configure, constant, multi
-
Methods inherited from class com.google.inject.AbstractModule
addError, addError, addError, bind, bind, bind, bindConstant, binder, bindInterceptor, bindListener, bindScope, configure, convertToTypes, currentStage, getMembersInjector, getMembersInjector, getProvider, getProvider, install, requestInjection, requestStaticInjection, requireBinding, requireBinding
-
-
-
-
Field Detail
-
filename
protected String filename
-
loggingPerEvaluation
protected boolean loggingPerEvaluation
-
loggingPerIteration
protected boolean loggingPerIteration
-
evaluationStep
protected int evaluationStep
-
iterationStep
protected int iterationStep
-
-
Method Detail
-
config
public void config()
Description copied from class:Opt4JModule
Configure the module. Bind constants, listeners, and bind arbitrary classes.- Specified by:
config
in classOpt4JModule
- See Also:
Binder
-
getFilename
public String getFilename()
Returns the filename.- Returns:
- the filename
- See Also:
setFilename(java.lang.String)
-
setFilename
public void setFilename(String filename)
Sets the filename.- Parameters:
filename
- the filename- See Also:
getFilename()
-
getEvaluationStep
public int getEvaluationStep()
Returns the step size of the evaluations.- Returns:
- the step size of the evaluations
- See Also:
setEvaluationStep(int)
-
setEvaluationStep
public void setEvaluationStep(int evaluationStep)
Sets the step size of the evaluations.- Parameters:
evaluationStep
- the step size of the evaluations- See Also:
getEvaluationStep()
-
getIterationStep
public int getIterationStep()
Returns the step size of the iterations.- Returns:
- the step size of the iterations
- See Also:
setIterationStep(int)
-
setIterationStep
public void setIterationStep(int iterationStep)
Sets the step size of the iterations.- Parameters:
iterationStep
- the step size of the iterations- See Also:
getIterationStep()
-
isLoggingPerEvaluation
public boolean isLoggingPerEvaluation()
Returnstrue
if the logger observes the number of evaluations.- Returns:
true
if the logger observes the number of evaluations
-
setLoggingPerEvaluation
public void setLoggingPerEvaluation(boolean loggingPerEvaluation)
Sets the observation for the number of evaluations.- Parameters:
loggingPerEvaluation
-true
if the logger observes the number of evaluations
-
isLoggingPerIteration
public boolean isLoggingPerIteration()
Returnstrue
if the logger observes the number of iterations.- Returns:
true
if the logger observes the number of iterations
-
setLoggingPerIteration
public void setLoggingPerIteration(boolean loggingPerIteration)
Sets the observation for the number of iterations.- Parameters:
loggingPerIteration
-true
if the logger observes the number of iterations
-
-