public class ProbeImpl extends java.lang.Object implements Probe, java.io.Serializable
Collects information from Probeable
objects.
Constructor and Description |
---|
ProbeImpl() |
Modifier and Type | Method and Description |
---|---|
void |
collect(float time)
Processes new data.
|
void |
connect(Probeable target,
java.lang.String stateName,
boolean record) |
void |
connect(java.lang.String ensembleName,
Probeable target,
java.lang.String stateName,
boolean record) |
TimeSeries |
getData() |
java.lang.String |
getEnsembleName() |
ProbeTask |
getProbeTask() |
java.lang.String |
getStateName() |
Probeable |
getTarget() |
boolean |
isInEnsemble() |
void |
reset()
Clears collected data.
|
void |
setSamplingRate(float rate) |
public void connect(java.lang.String ensembleName, Probeable target, java.lang.String stateName, boolean record) throws SimulationException
connect
in interface Probe
ensembleName
- Name of the Ensemble the target object belongs to. Null, if
the target is a top-level node.target
- The object about which state history is to be collectedstateName
- The name of the state variable to collectrecord
- If true, getData() returns history since last connect() or
reset(), otherwise getData() returns most recent sampleSimulationException
- if the given target does not have the given stateProbe.connect(java.lang.String, ca.nengo.model.Probeable, java.lang.String, boolean)
public void connect(Probeable target, java.lang.String stateName, boolean record) throws SimulationException
connect
in interface Probe
target
- The object about which state history is to be collectedstateName
- The name of the state variable to collectrecord
- If true, getData() returns history since last connect() or
reset(), otherwise getData() returns most recent sampleSimulationException
- if the given target does not have the given stateProbe.connect(Probeable, String, boolean)
public void reset()
Probe
reset
in interface Probe
Probe.reset()
public void collect(float time)
Probe
collect
in interface Probe
Probe.collect(float)
public TimeSeries getData()
getData
in interface Probe
Probe.getData()
public void setSamplingRate(float rate)
setSamplingRate
in interface Probe
rate
- Rate in samples per second. The default is one sample per network time step, and it is
not possible to sample faster than this (specifying a higher sampling rate has no effect).Probe.setSamplingRate(float)
public Probeable getTarget()
getTarget
in interface Probe
Probe.getTarget()
public java.lang.String getStateName()
getStateName
in interface Probe
Probe.getStateName()
public boolean isInEnsemble()
isInEnsemble
in interface Probe
Probe.isInEnsemble()
public java.lang.String getEnsembleName()
getEnsembleName
in interface Probe
Probe.getEnsembleName()
public ProbeTask getProbeTask()
getProbeTask
in interface Probe
Probe.getProbeTask()