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

## Operator.Operations
Class SelectionOperation

    java.lang.Object
      Operator.Operations.SelectionOperation

All Implemented Interfaces:
  Operation, ParameterI

Direct Known Subclasses:
  EliteOperationSelection, LSystemSelect, RouletteWheel, TournamentSelect, UserSelect

    public abstract class SelectionOperation

extends java.lang.Object
implements Operation

Abstract SelectionOperation class. Has a selectedPopulation and the size of the selection

Field Summary
`protected Population` | `selectedPopulation`
`protected int` | `size`

Constructor Summary
`SelectionOperation()` New instance
`SelectionOperation(int size)` New instance
`SelectionOperation(java.util.Properties p)` New instance

Method Summary
`abstract void` | `doOperation(Individual operand)` Performs the operation on an operand
`abstract void` | `doOperation(java.util.List<Individual> operands)` Performs the operation on the list passed
`Population` | `getSelectedPopulation()` Returns the selected population.
`int` | `getSize()` Size of the population to be selecetd
`void` | `setProperties(java.util.Properties p)` Set properties

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### selectedPopulation

    protected Population selectedPopulation

### size

    protected int size

Constructor Detail

### SelectionOperation

    public SelectionOperation(int size)

  New instance

  Parameters:
    `size` - size of selection

### SelectionOperation

    public SelectionOperation(java.util.Properties p)

  New instance

  Parameters:
    `p` - properties

### SelectionOperation

    public SelectionOperation()

  New instance

Method Detail

### setProperties

    public void setProperties(java.util.Properties p)

  Set properties

  Specified by:
    `setProperties` in interface `ParameterI`
  Parameters:
    `p` - object containing properties

### doOperation

    public abstract void doOperation(Individual operand)

  Description copied from interface: `Operation`
  Performs the operation on an operand

  Specified by:
    `doOperation` in interface `Operation`
  Parameters:
    `operand` - operand to perform operation on

### doOperation

    public abstract void doOperation(java.util.List<Individual> operands)

  Description copied from interface: `Operation`
  Performs the operation on the list passed

  Specified by:
    `doOperation` in interface `Operation`
  Parameters:
    `operands` - operands to be operated on

### getSelectedPopulation

    public Population getSelectedPopulation()

  Returns the selected population.

  Returns:
    Selected population

### getSize

    public int getSize()

  Size of the population to be selecetd

  Returns:
    selected population size

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