Package org.opt4j.operators
Class OperatorModule<P extends Operator>
java.lang.Object
com.google.inject.AbstractModule
org.opt4j.core.start.Opt4JModule
org.opt4j.operators.OperatorModule<P>
- Type Parameters:
P
- The specific operator with a wildcard (?).
- All Implemented Interfaces:
Module
- Direct Known Subclasses:
CopyModule
,CrossoverModule
,DiversityModule
,MutateModule
,NeighborModule
Module class for an
Operator
.-
Field Summary
Fields inherited from class org.opt4j.core.start.Opt4JModule
SINGLETON
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addOperator
(Class<? extends Genotype> genotype, Class<? extends P> operator) void
addOperator
(Class<? extends P> operator) Add anOperator
.void
addOperator
(AbstractGenericOperator.OperatorPredicate predicate, Class<? extends P> operator) Methods inherited from class org.opt4j.core.start.Opt4JModule
addControlListener, addIndividualStateListener, addOptimizerIterationListener, addOptimizerStateListener, bindConstant, bindConstant, bindConstant, constant
Methods inherited from class com.google.inject.AbstractModule
configure
-
Constructor Details
-
OperatorModule
public OperatorModule()
-
-
Method Details
-
addOperator
Add anOperator
.- Parameters:
operator
- the operator to be added
-
addOperator
public void addOperator(AbstractGenericOperator.OperatorPredicate predicate, Class<? extends P> operator) - Parameters:
predicate
- the predicateoperator
- the operator
-
addOperator
- Parameters:
genotype
- the genotype classoperator
- the operator
-