Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## Individuals
Interface Individual

All Superinterfaces:
  java.lang.Cloneable, java.lang.Comparable<Individual>

All Known Implementing Classes:
  AbstractIndividual, GEIndividual

    public interface Individual

extends java.lang.Cloneable, java.lang.Comparable<Individual>

This interface defines the methods for individual objects. Individuals are intended to be a container class that includes a genotype, a fitness object, a phenotype, and a mapper. It doesnt really need to do a lot beyond implementing a map() method, which predictably enough maps from genotype to a phenotype.

Author:
  Blip

Method Summary
`Individual` | `clone()` Clone the individual
`int` | `getAge()` The age of the individual, counted as how many iterations it has survived.
`Fitness` | `getFitness()` Get fitness of individuals
`Genotype` | `getGenotype()` Get the genotype
`Mapper` | `getMapper()` Get the map use to map input and output
`Phenotype` | `getPhenotype()` Get phenotype
`java.lang.String` | `getPhenotypeString(int map)` Get a String representation of the output(Phenotype)
`boolean` | `isEvaluated()` Has the individual been evaluated
`boolean` | `isValid()` Get the validity of the individual
`void` | `map(int map)` Map the input(Genotype) to output(Phenotype) using a grammar as a map
`void` | `setAge(int age)` Age is how long the individual has existed
`void` | `setEvaluated(boolean b)` Indicate if the individual should be evaluated or not
`void` | `setFitness(Fitness f)` Set fitness
`void` | `setGenotype(Genotype g)` Set genotype
`void` | `setMapper(Mapper m)` Set mapper
`void` | `setPhenotype(Phenotype p)` Set phenotype
`void` | `setValid(boolean b)` Set the validity of the individual

Methods inherited from interface java.lang.Comparable
`compareTo`

Method Detail

### map

    void map(int map)

  Map the input(Genotype) to output(Phenotype) using a grammar as a map

  Parameters:
    `map` - which input to map if there are multiple

### getFitness

    Fitness getFitness()

  Get fitness of individuals

  Returns:
    individual fitness

### getGenotype

    Genotype getGenotype()

  Get the genotype

  Returns:
    genotype

### getMapper

    Mapper getMapper()

  Get the map use to map input and output

  Returns:
    map used

### getPhenotype

    Phenotype getPhenotype()

  Get phenotype

  Returns:
    phenotype

### getPhenotypeString

    java.lang.String getPhenotypeString(int map)

  Get a String representation of the output(Phenotype)

  Parameters:
    `map` - which output to get if there are multiple
  Returns:
    string of output

### setFitness

    void setFitness(Fitness f)

  Set fitness

  Parameters:
    `f` - fitness

### setGenotype

    void setGenotype(Genotype g)

  Set genotype

  Parameters:
    `g` - genotype

### setMapper

    void setMapper(Mapper m)

  Set mapper

  Parameters:
    `m` - mapper

### setPhenotype

    void setPhenotype(Phenotype p)

  Set phenotype

  Parameters:
    `p` - phenotype

### isEvaluated

    boolean isEvaluated()

  Has the individual been evaluated

  Returns:
    boolean of evaluation status

### setEvaluated

    void setEvaluated(boolean b)

  Indicate if the individual should be evaluated or not

  Parameters:
    `b` - set if individual should be evaluated

### isValid

    boolean isValid()

  Get the validity of the individual

  Returns:
    validity of the individual

### setValid

    void setValid(boolean b)

  Set the validity of the individual

  Parameters:
    `b` - validity to be set

### clone

    Individual clone()

  Clone the individual

  Returns:
    a clone of the individual

### setAge

    void setAge(int age)

  Age is how long the individual has existed

  Parameters:
    `age` - How long the individual has existed

### getAge

    int getAge()

  The age of the individual, counted as how many iterations it has survived.

  Returns:
    number of iterations survived

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD