etomica.atom
Class AtomPair
java.lang.Object
etomica.atom.AtomPair
- All Implemented Interfaces:
- IAtomList, Serializable
public class AtomPair
- extends Object
- implements IAtomList, Serializable
Data structure that contains two mutable atom instances.
- See Also:
- Serialized Form
atom0
public IAtom atom0
atom1
public IAtom atom1
AtomPair
public AtomPair()
AtomPair
public AtomPair(IAtom atom0,
IAtom atom1)
getAtom
public final IAtom getAtom(int i)
- Description copied from interface:
IAtomList
- Returns the i-th atom, with numbering beginning from 0.
If i is greater than count-1, throws an IllegalArgumentException.
- Specified by:
getAtom in interface IAtomList
getAtomCount
public final int getAtomCount()
- Specified by:
getAtomCount in interface IAtomList
- Returns:
- the number of atoms in the set
toString
public String toString()
- Overrides:
toString in class Object