etomica.nbr
Class CriterionType
java.lang.Object
etomica.nbr.CriterionAdapter
etomica.nbr.CriterionType
- All Implemented Interfaces:
- NeighborCriterion, Serializable
public class CriterionType
- extends CriterionAdapter
Filters atoms to match a given AtomType.
- See Also:
- Serialized Form
|
Method Summary |
boolean |
accept(IAtomList atom)
Returns true if the AtomType of the atom matches the AtomType given at
construction and if the wrapped criterion accept also returns true. |
IAtomType |
getType()
Returns the AtomType accepted by this criterion. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CriterionType
public CriterionType(NeighborCriterion criterion,
IAtomType type)
accept
public boolean accept(IAtomList atom)
- Returns true if the AtomType of the atom matches the AtomType given at
construction and if the wrapped criterion accept also returns true.
- Specified by:
accept in interface NeighborCriterion- Specified by:
accept in class CriterionAdapter
getType
public IAtomType getType()
- Returns the AtomType accepted by this criterion.