|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectetomica.nbr.CriterionAdapter
public abstract class CriterionAdapter
Wraps another criterion while adding additional criteria to the acceptance decision. Used to introduce criteria related to the species, molecule, and other identifiers of the pair. Does not normally consider atom positions, but defers this to the wrapped iterator. Consequently the methods needUpdate, unsafe, and others that related to the atom configurations are simply passed on to the wrapped criterion.
| Field Summary | |
|---|---|
protected NeighborCriterion |
subCriterion
|
| Constructor Summary | |
|---|---|
CriterionAdapter(NeighborCriterion criterion)
Constructs criterion that wraps the given criterion. |
|
| Method Summary | |
|---|---|
abstract boolean |
accept(IAtomList pair)
Implementation of this method should introduce new criterion and return true if pair meets this criterion and that of the wrapped NeighborCriterion. |
NeighborCriterion |
getWrappedCriterion()
Returns the criterion wrapped by this adapter |
boolean |
needUpdate(IAtom atom)
Indicates whether the neighbor list for the given atom should be updated, according to the wrapped criterion. |
void |
reset(IAtom atom)
Indicates to wrapped criterion that given atom's neighbor list has just been updated, and that properties (e.g., record of atom's position) used by needUpdate and unsafe() methods should be reset. |
void |
setBox(IBox box)
Specifies to the wrapped criterion the box where the criterion is being applied. |
boolean |
unsafe()
Indicates whether the atom has changed (e.g. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final NeighborCriterion subCriterion
| Constructor Detail |
|---|
public CriterionAdapter(NeighborCriterion criterion)
criterion - | Method Detail |
|---|
public final NeighborCriterion getWrappedCriterion()
public abstract boolean accept(IAtomList pair)
accept in interface NeighborCriterionpublic boolean needUpdate(IAtom atom)
needUpdate in interface NeighborCriterionpublic void setBox(IBox box)
setBox in interface NeighborCriterionpublic boolean unsafe()
unsafe in interface NeighborCriterionpublic void reset(IAtom atom)
reset in interface NeighborCriterion
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||