public class DiameterHashByType extends java.lang.Object implements DiameterHash, AtomTypeAgentManager.AgentSource
Modifier and Type | Field and Description |
---|---|
protected AtomTypeAgentManager |
agentManager |
Constructor and Description |
---|
DiameterHashByType(ISimulation sim) |
Modifier and Type | Method and Description |
---|---|
double |
getDiameter(IAtom atom)
Returns an appropriate diameter for the given atom.
|
double |
getDiameter(IAtomType atomType) |
java.lang.Class |
getSpeciesAgentClass()
Returns the Class of the agent.
|
java.lang.Object |
makeAgent(IAtomType type)
Returns an agent for the given AtomType.
|
void |
releaseAgent(java.lang.Object agent,
IAtomType type)
This informs the agent source that the agent is going away and that
the agent source should disconnect the agent from other elements.
|
void |
setDiameter(IAtomType type,
double newDiameter) |
protected final AtomTypeAgentManager agentManager
public DiameterHashByType(ISimulation sim)
public double getDiameter(IAtom atom)
DiameterHash
getDiameter
in interface DiameterHash
public double getDiameter(IAtomType atomType)
public void setDiameter(IAtomType type, double newDiameter)
public java.lang.Class getSpeciesAgentClass()
AtomTypeAgentManager.AgentSource
getSpeciesAgentClass
in interface AtomTypeAgentManager.AgentSource
public java.lang.Object makeAgent(IAtomType type)
AtomTypeAgentManager.AgentSource
makeAgent
in interface AtomTypeAgentManager.AgentSource
public void releaseAgent(java.lang.Object agent, IAtomType type)
AtomTypeAgentManager.AgentSource
releaseAgent
in interface AtomTypeAgentManager.AgentSource