public class NestedBoolean
extends org.jgap.gp.CommandGene
implements org.jgap.gp.IMutateable, org.jgap.util.ICloneable
| Constructor and Description |
|---|
NestedBoolean(String op,
org.jgap.gp.impl.GPConfiguration a_conf)
Basic Constructor.
|
NestedBoolean(String op,
org.jgap.gp.impl.GPConfiguration a_conf,
Class<?> a_returnType,
boolean mutable)
Constructor to define return type, and if NestedBoolean supports mutation.
|
| Modifier and Type | Method and Description |
|---|---|
org.jgap.gp.CommandGene |
applyMutation(int a_index,
double a_percentage) |
Object |
clone()
Clones the object.
|
Object |
execute_object(org.jgap.gp.impl.ProgramChromosome a_chrom,
int a_n,
Object[] args)
Executes this CommandGene as object.
|
void |
execute_void(org.jgap.gp.impl.ProgramChromosome a_chrom,
int a_n,
Object[] args) |
Class<?> |
getChildType(org.jgap.gp.IGPProgram a_ind,
int a_chromNum)
We expect the first 2 parameters to be resource identifier, the third to be an
(optional) double value as the threshold for this Similarity command.
|
String |
toString() |
check, check, cleanup, compareTo, dynamizeArity, ensureUniqueness, ensureUniqueness, ensureUniqueness2, equals, execute_boolean, execute_double, execute_float, execute_int, execute_long, execute, getAllele, getApplicationData, getArity, getArityMax, getArityMin, getCommandType, getEnergy, getGPConfiguration, getInternalValue, getName, getPersistentRepresentation, getPersistentRepresentationExt, getReturnType, getSubChildType, getSubChildTypes, getSubReturnType, hashCode, init, isAffectGlobalState, isCompareApplicationData, isFloatType, isIntegerType, isValid, isValid, setAllele, setApplicationData, setArity, setArityMax, setArityMin, setCompareApplicationData, setEnergy, setNoValidation, setReturnType, setToRandomValue, setValueFromPersistentRepresentation, setValueFromString, sizepublic NestedBoolean(String op, org.jgap.gp.impl.GPConfiguration a_conf) throws org.jgap.InvalidConfigurationException
op - Name of the boolean operator.a_conf - a_conf A JGAP GPconfiguration instance.org.jgap.InvalidConfigurationException - when an invalid value has been passed to a Configuration objectpublic NestedBoolean(String op, org.jgap.gp.impl.GPConfiguration a_conf, Class<?> a_returnType, boolean mutable) throws org.jgap.InvalidConfigurationException
op - Name of the boolean operator.a_conf - A JGAP GPconfiguration instance.a_returnType - Define the return type of this node.mutable - true means command(AND, OR, XOR) can mutate.org.jgap.InvalidConfigurationException - when an invalid value has been passed to a Configuration objectpublic String toString()
toString in class org.jgap.gp.CommandGenepublic Class<?> getChildType(org.jgap.gp.IGPProgram a_ind, int a_chromNum)
getChildType in class org.jgap.gp.CommandGenea_ind - A GPPrograma_chromNum - The number of the chromosome.public Object execute_object(org.jgap.gp.impl.ProgramChromosome a_chrom, int a_n, Object[] args)
"sim(a.resource, b.resource)|threshold".execute_object in class org.jgap.gp.CommandGenepublic void execute_void(org.jgap.gp.impl.ProgramChromosome a_chrom,
int a_n,
Object[] args)
execute_void in class org.jgap.gp.CommandGenepublic Object clone()
public org.jgap.gp.CommandGene applyMutation(int a_index,
double a_percentage)
throws org.jgap.InvalidConfigurationException
applyMutation in interface org.jgap.gp.IMutateableorg.jgap.InvalidConfigurationExceptionCopyright © 2020. All rights reserved.