MoleculeAgentManager.MoleculeAgentSource, NeighborCriterionMolecularpublic class CriterionSimpleMolecular extends java.lang.Object implements NeighborCriterionMolecular, MoleculeAgentManager.MoleculeAgentSource
| Modifier and Type | Field | Description |
|---|---|---|
protected MoleculeAgentManager |
agentManager |
|
protected Boundary |
boundary |
|
protected BoxAgentManager<MoleculeAgentManager> |
boxAgentManager |
|
protected double |
displacementLimit2 |
|
protected Vector |
dr |
|
protected double |
interactionRange |
|
protected IMoleculePositionDefinition |
moleculeSite |
|
protected double |
neighborRadius2 |
|
protected double |
r2 |
|
protected double |
r2MaxSafe |
|
protected double |
safetyFactor |
|
protected Space |
space |
| Constructor | Description |
|---|---|
CriterionSimpleMolecular(Simulation sim,
Space _space,
double interactionRange,
double neighborRadius) |
| Modifier and Type | Method | Description |
|---|---|---|
boolean |
accept(IMoleculeList pair) |
|
double |
getInteractionRange() |
|
Dimension |
getInteractionRangeDimension() |
|
double |
getNeighborRange() |
|
Dimension |
getNeighborRangeDimension() |
|
double |
getSafetyFactor() |
|
java.lang.Object |
makeAgent(IMolecule molecule) |
Returns an agent for the given Atom.
|
boolean |
needUpdate(IMolecule molecule) |
Indicates whether the neighbor list for the given molecule should
be updated, according to this criterion.
|
void |
releaseAgent(java.lang.Object agent,
IMolecule molecule) |
This informs the agent source that the agent is going away and that
the agent source should disconnect the agent from other elements
|
void |
reset(IMolecule molecule) |
Indicates to criterion that given molecule's neighbor list has just been
updated, and that properties (e.g., record of molecule's position)
used by needUpdate and unsafe() methods should be reset.
|
void |
setBox(Box box) |
Specifies the box where the criterion is being applied.
|
void |
setInteractionRange(double newInteractionRange) |
|
void |
setMoleculePosition(IMoleculePositionDefinition positionDefinition) |
|
void |
setNeighborRange(double r) |
|
void |
setSafetyFactor(double f) |
|
boolean |
unsafe() |
Indicates whether the molecule has changed (e.g.
|
protected final Space space
protected double interactionRange
protected double displacementLimit2
protected double neighborRadius2
protected final Vector dr
protected Boundary boundary
protected double safetyFactor
protected double r2
protected double r2MaxSafe
protected MoleculeAgentManager agentManager
protected final BoxAgentManager<MoleculeAgentManager> boxAgentManager
protected IMoleculePositionDefinition moleculeSite
public CriterionSimpleMolecular(Simulation sim, Space _space, double interactionRange, double neighborRadius)
public void setMoleculePosition(IMoleculePositionDefinition positionDefinition)
public void setSafetyFactor(double f)
public double getSafetyFactor()
public void setNeighborRange(double r)
public double getNeighborRange()
public Dimension getNeighborRangeDimension()
public void setInteractionRange(double newInteractionRange)
public double getInteractionRange()
public Dimension getInteractionRangeDimension()
public boolean needUpdate(IMolecule molecule)
NeighborCriterionMolecularneedUpdate in interface NeighborCriterionMolecularpublic void setBox(Box box)
NeighborCriterionMolecularsetBox in interface NeighborCriterionMolecularpublic boolean unsafe()
NeighborCriterionMolecularunsafe in interface NeighborCriterionMolecularpublic boolean accept(IMoleculeList pair)
accept in interface NeighborCriterionMolecularpublic void reset(IMolecule molecule)
NeighborCriterionMolecularreset in interface NeighborCriterionMolecularpublic java.lang.Object makeAgent(IMolecule molecule)
MoleculeAgentManager.MoleculeAgentSourcemakeAgent in interface MoleculeAgentManager.MoleculeAgentSourcepublic void releaseAgent(java.lang.Object agent,
IMolecule molecule)
MoleculeAgentManager.MoleculeAgentSourcereleaseAgent in interface MoleculeAgentManager.MoleculeAgentSource