Specialization of ChannelFacetScalar for SingleChannel. More...
#include <Channels/ChannelFacetScalar.H>
Public Member Functions | |
virtual | ~ChannelFacetScalarSingle () |
Destructor. | |
void | setVal (const uint clev, const uint slev, const double val) |
Set a value. | |
void | setVal (const uint idx, const double val) |
Set a value. | |
double | getVal (const uint clev, const uint slev) const |
Get a value. | |
double | getVal (const uint idx) const |
Get a value. | |
virtual void | writeTo (ParamMap &pmap) const |
Write our data out to a ParamMap. | |
virtual void | readFrom (const ParamMap &pmap) |
Read our data back in from a ParamMap. | |
Protected Member Functions | |
ChannelFacetScalarSingle (const SingleChannel &chan, const double initval) | |
Constructor. | |
Protected Attributes | |
const LevelSpec | itsLevelSpec |
Keep track of our channel's info. |
Specialization of ChannelFacetScalar for SingleChannel.
This class holds one scalar parameter per feature map of the SingleChannel. Note that since the LevelSpec is used internally at constructions to determine how many feature maps are in each SingleChannel, this should not be constructed until after the model has been start()'ed so that the LevelSpec is valid. Typically, PreFrontalCortex would be in charge of installing these facets by using a ChannelVisitor depending on the type of extra top-down attention components being used.
Definition at line 83 of file ChannelFacetScalar.H.
ChannelFacetScalarSingle::~ChannelFacetScalarSingle | ( | ) | [virtual] |
Destructor.
Definition at line 65 of file ChannelFacetScalar.C.
ChannelFacetScalarSingle::ChannelFacetScalarSingle | ( | const SingleChannel & | chan, | |
const double | initval | |||
) | [protected] |
Constructor.
Definition at line 58 of file ChannelFacetScalar.C.
double ChannelFacetScalarSingle::getVal | ( | const uint | idx | ) | const |
Get a value.
Definition at line 85 of file ChannelFacetScalar.C.
References LevelSpec::csToIndex(), and itsLevelSpec.
void ChannelFacetScalarSingle::readFrom | ( | const ParamMap & | pmap | ) | [virtual] |
Read our data back in from a ParamMap.
Implements ChannelFacet.
Definition at line 110 of file ChannelFacetScalar.C.
References ParamMap::getDoubleParam(), ParamMap::hasParam(), LevelSpec::indexToCS(), itsLevelSpec, LevelSpec::maxIndex(), and sformat().
void ChannelFacetScalarSingle::setVal | ( | const uint | idx, | |
const double | val | |||
) |
Set a value.
Definition at line 70 of file ChannelFacetScalar.C.
References LevelSpec::csToIndex(), and itsLevelSpec.
void ChannelFacetScalarSingle::writeTo | ( | ParamMap & | pmap | ) | const [virtual] |
Write our data out to a ParamMap.
Implements ChannelFacet.
Definition at line 99 of file ChannelFacetScalar.C.
References LevelSpec::indexToCS(), itsLevelSpec, LevelSpec::maxIndex(), ParamMap::putDoubleParam(), and sformat().
const LevelSpec ChannelFacetScalarSingle::itsLevelSpec [protected] |
Keep track of our channel's info.
Definition at line 111 of file ChannelFacetScalar.H.
Referenced by getVal(), readFrom(), setVal(), and writeTo().