11#include "LibCyberRadio/Driver/RadioHandler.h"
12#include "LibCyberRadio/Driver/RadioComponent.h"
39 _parent(other._parent),
40 _enabled(other._enabled)
49 _index = other._index;
50 _parent = other._parent;
51 _enabled = other._enabled;
100 if ( cfg.
hasKey(
"enable") && _config.hasKey(
"enable") )
102 ret =
enable( _config[
"enable"].asBool() );
118 _config[
"enable"] = _enabled;
125 if ( _config.hasKey(
"enable") )
virtual int debug(const char *format,...)
Outputs debug information.
virtual bool setConfiguration(ConfigurationDict &cfg)
Sets the configuration dictionary for this object.
virtual Configurable & operator=(const Configurable &other)
Assignment operator for Configurable objects.
Configurable(const std::string &name="<unknown>", bool debug=false)
Constructs a Configurable object.
virtual bool setConfigurationValueToBool(const std::string &key, const bool value)
Sets a named configuration value to a Boolean.
A configuration dictionary.
virtual bool hasKey(const std::string &key) const
Determines if the dictionary has the given key.
virtual bool enable(bool enabled=true)
Enables this component.
virtual bool setConfiguration(ConfigurationDict &cfg)
Sets the configuration dictionary for this component.
virtual int getIndex() const
Gets the index number of the component.
virtual void setIndex(int index)
Sets the index number of the component.
virtual void queryConfiguration()
Tells the component to query its hardware configuration in order to create its configuration dictiona...
virtual bool isEnabled() const
Gets whether or not the component is enabled.
virtual ~RadioComponent()
Destroys a RadioComponent object.
virtual void updateConfigurationDict()
Updates the configuration dictionary from component settings.
virtual RadioComponent & operator=(const RadioComponent &other)
Assignment operator for RadioComponent objects.
RadioComponent(const std::string &name="<unknown>", int index=0, RadioHandler *parent=NULL, bool debug=false)
Constructs a RadioComponent object.
virtual void initConfigurationDict()
Initializes the configuration dictionary, defining the allowed keys.
virtual RadioHandler * getParent() const
Gets the "parent" radio handler for this component.
virtual bool disable()
Disables this component.
virtual void setParent(RadioHandler *parent)
Sets the "parent" radio handler for this component.
Generic radio handler class.
Provides programming elements for driving CRS NDR-class radios.
Defines functionality for LibCyberRadio applications.