|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sourceforge.cilib.entity.AbstractTopology<E> net.sourceforge.cilib.entity.topologies.GBestTopology<E> net.sourceforge.cilib.entity.topologies.LBestTopology<E>
E
- The Entity type.public class LBestTopology<E extends Entity>
Implementation of the Local Best Neighbourhood topology.
References:
Nested Class Summary |
---|
Nested classes/interfaces inherited from class net.sourceforge.cilib.entity.topologies.GBestTopology |
---|
GBestTopology.IndexedIterator<T extends Entity> |
Field Summary |
---|
Fields inherited from class net.sourceforge.cilib.entity.topologies.GBestTopology |
---|
entities |
Constructor Summary | |
---|---|
LBestTopology()
Creates a new instance of LBestTopology . |
|
LBestTopology(LBestTopology<E> copy)
Copy constructor. |
Method Summary | |
---|---|
LBestTopology<E> |
getClone()
Create a cloned copy of the current object and return it. |
int |
getNeighbourhoodSize()
Accessor for the number of particles in a neighbourhood. |
Iterator<E> |
neighbourhood(Iterator<? extends Entity> iterator)
Recalculate the neighbourhoodSize by updating the
ControlParameter and then construct a new iterator to be returned. |
void |
setNeighbourhoodSize(ControlParameter neighbourhoodSize)
Sets the ControlParameter that should be used to determine the number of particles in the neighbourhood of each particle. |
Methods inherited from class net.sourceforge.cilib.entity.topologies.GBestTopology |
---|
add, add, addAll, addAll, asList, clear, contains, containsAll, equals, get, getId, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, remove, removeAll, retainAll, set, setId, size, subList, toArray, toArray |
Methods inherited from class net.sourceforge.cilib.entity.AbstractTopology |
---|
accept, accept, clearBestEntity, getBestEntity, getBestEntity, update |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LBestTopology()
LBestTopology
. The default
neighbourhoodSize
is a ConstantControlParameter with it's parameter set to
3.
public LBestTopology(LBestTopology<E> copy)
copy
- The instance to copy.Method Detail |
---|
public LBestTopology<E> getClone()
getClone
in interface Topology<E extends Entity>
getClone
in interface Cloneable
getClone
in class GBestTopology<E extends Entity>
Object.clone()
public Iterator<E> neighbourhood(Iterator<? extends Entity> iterator)
neighbourhoodSize
by updating the
ControlParameter
and then construct a new iterator to be returned.
neighbourhood
in interface Topology<E extends Entity>
neighbourhood
in class GBestTopology<E extends Entity>
iterator
- The Iterator to wrap.
public void setNeighbourhoodSize(ControlParameter neighbourhoodSize)
neighbourhoodSize
- The ControlParameter to use.public int getNeighbourhoodSize()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |