etomica.nbr
Class CriterionAll

java.lang.Object
  extended by etomica.nbr.CriterionAll
All Implemented Interfaces:
NeighborCriterion, Serializable

public class CriterionAll
extends Object
implements NeighborCriterion, Serializable

Specifies that all atoms pairs are to be considered neighbors. Should not be used for species in which atoms are being added/removed by integrator.

See Also:
Serialized Form

Constructor Summary
CriterionAll()
           
 
Method Summary
 boolean accept(IAtomList pair)
          Always returns true, indicating that all atoms pairs are neighbors.
 boolean needUpdate(IAtom atom)
          Always returns false, indicating that neighbor list never needs updating.
 void reset(IAtom atom)
          Performs no action.
 void setBox(IBox box)
          Performs no action.
 boolean unsafe()
          Always returns false, indicating that neighbor list never needs updating.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CriterionAll

public CriterionAll()
Method Detail

needUpdate

public boolean needUpdate(IAtom atom)
Always returns false, indicating that neighbor list never needs updating. This is appropriate if atoms are never added to or removed from box, because all atoms are always on neighbor list.

Specified by:
needUpdate in interface NeighborCriterion
Returns:
true if the atom's list should be updated.

setBox

public void setBox(IBox box)
Performs no action.

Specified by:
setBox in interface NeighborCriterion

unsafe

public boolean unsafe()
Always returns false, indicating that neighbor list never needs updating. This is appropriate if atoms are never added to or removed from box, because all atoms are always on neighbor list.

Specified by:
unsafe in interface NeighborCriterion

reset

public void reset(IAtom atom)
Performs no action.

Specified by:
reset in interface NeighborCriterion

accept

public boolean accept(IAtomList pair)
Always returns true, indicating that all atoms pairs are neighbors.

Specified by:
accept in interface NeighborCriterion