Class VariableLengthVectorRepresentation
java.lang.Object
com.knezevic.edaf.v3.repr.impl.VariableLengthVectorRepresentation
- All Implemented Interfaces:
Representation<VariableLengthVector<Integer>>
public final class VariableLengthVectorRepresentation
extends Object
implements Representation<VariableLengthVector<Integer>>
Minimal variable-length integer token representation scaffold.
-
Constructor Summary
ConstructorsConstructorDescriptionVariableLengthVectorRepresentation(int minLength, int maxLength, int maxToken) -
Method Summary
Modifier and TypeMethodDescriptionbooleanisValid(VariableLengthVector<Integer> genotype) Returns true if the genotype is valid in this domain.Creates a random feasible genotype.repair(VariableLengthVector<Integer> genotype) Repairs a genotype into the feasible domain.summarize(VariableLengthVector<Integer> genotype) Provides a stable summary for logs and reports.type()Representation identifier used in configuration and logs.
-
Constructor Details
-
VariableLengthVectorRepresentation
public VariableLengthVectorRepresentation(int minLength, int maxLength, int maxToken)
-
-
Method Details
-
type
Description copied from interface:RepresentationRepresentation identifier used in configuration and logs.- Specified by:
typein interfaceRepresentation<VariableLengthVector<Integer>>
-
random
Description copied from interface:RepresentationCreates a random feasible genotype.- Specified by:
randomin interfaceRepresentation<VariableLengthVector<Integer>>
-
isValid
Description copied from interface:RepresentationReturns true if the genotype is valid in this domain.- Specified by:
isValidin interfaceRepresentation<VariableLengthVector<Integer>>
-
repair
Description copied from interface:RepresentationRepairs a genotype into the feasible domain.- Specified by:
repairin interfaceRepresentation<VariableLengthVector<Integer>>
-
summarize
Description copied from interface:RepresentationProvides a stable summary for logs and reports.- Specified by:
summarizein interfaceRepresentation<VariableLengthVector<Integer>>
-