CDPPropertyChannel Class
(ServerIO::CDPPropertyChannel)The CDPPropertyChannel template-class is ACDPBaseChannel implementation based on CDPProperty. More...
Header: | #include <IO/ServerIO/CDPPropertyChannel.h> |
Inherits: | ACDPBaseChannel<T> |
Public Functions
CDPPropertyChannel() | |
virtual | ~CDPPropertyChannel() |
Reimplemented Public Functions
virtual void | AddProperty(std::string name, std::string value) override |
virtual void | Configure(XMLElementEx *pSignalXML) override |
virtual void | Create(const char *name, CDPComponent *pParent) override |
virtual void | Destroy() override |
virtual bool | GetData(void *data, unsigned int size = 0, double *timestamp = nullptr) override |
virtual std::string | GetProperty(const std::string &propertyName) override |
virtual bool | IsInput() override |
virtual const char * | Name() const override |
virtual bool | PutData(const void *data, unsigned int size = 0, double timestamp = 0.0) override |
virtual void | SetChannelParameters(bool input, int moduleNo, int channelGroup, int channelNo) override |
virtual void | SetDataPointer(void *data, double *timeStamp = nullptr, std::optional<unsigned int> size = {}) override |
virtual void | SetProperty(std::string name, std::string value) override |
virtual void | SyncIn() override |
virtual void | SyncOut() override |
- 10 public functions inherited from ServerIO::ACDPBaseChannel
- 12 public functions inherited from ServerIO::ICDPChannel
- 8 public functions inherited from ServerIO::IChannel
- 26 public functions inherited from CDP::StudioAPI::CDPNode
- 22 public functions inherited from CDP::StudioAPI::ICDPNode
Reimplemented Protected Functions
virtual T | GetExternal() const override |
virtual T | GetInternal(double &timeStamp) const override |
virtual void | IssueBadDataSizeError(const char *methodName, unsigned int size) override |
virtual void | SetExternal(T newValue) override |
virtual void | SetInternal(T newValue, double timeStamp) override |
- 16 protected functions inherited from ServerIO::ACDPBaseChannel
- 2 protected functions inherited from ServerIO::IChannel
- 1 protected function inherited from CDP::StudioAPI::CDPNode
Protected Variables
CDPProperty<T> | m_property |
- 3 protected variables inherited from ServerIO::ACDPBaseChannel
Detailed Description
The CDPPropertyChannel template-class is ACDPBaseChannel implementation based on CDPProperty.
This class is final and IChannel interface members are threadsafe for user thread that runs SynchronizeValuesIn() and SynchronizeValuesOut() through ChannelManager.
See also ServerIO::CDPPropertyChannelFactory, IOServer, ServerIO, ServerIO::ACDPBaseChannel, ServerIO::ICDPChannel, ServerIO::IChannel, ServerIO::CDPSignalChannel, and ServerIO::ComponentStateChannel.
Member Function Documentation
CDPPropertyChannel::CDPPropertyChannel()
Default constructs an instance of CDPPropertyChannel.
[virtual]
CDPPropertyChannel::~CDPPropertyChannel()
Releases memory.
[override virtual]
void CDPPropertyChannel::AddProperty(std::string name, std::string value)
Reimplemented from ICDPChannel::AddProperty().
[override virtual]
void CDPPropertyChannel::Configure(XMLElementEx *pSignalXML)
Reimplemented from ICDPChannel::Configure().
[override virtual]
void CDPPropertyChannel::Create(const char *name, CDPComponent *pParent)
Reimplemented from ICDPChannel::Create().
[override virtual]
void CDPPropertyChannel::Destroy()
[override virtual]
bool CDPPropertyChannel::GetData(void *data, unsigned int size = 0, double *timestamp = nullptr)
Reimplemented from IChannel::GetData().
[override virtual protected]
T CDPPropertyChannel::GetExternal() const
Reimplemented from ACDPBaseChannel::GetExternal().
Returns the value of m_property
as type T.
[override virtual protected]
T CDPPropertyChannel::GetInternal(double &timeStamp) const
Reimplemented from ACDPBaseChannel::GetInternal().
Returns value of m_property
, called from ACDPBaseChannel::SyncIn().
[override virtual]
std::string CDPPropertyChannel::GetProperty(const std::string &propertyName)
Reimplemented from ICDPChannel::GetProperty().
[override virtual]
bool CDPPropertyChannel::IsInput()
Reimplemented from IChannel::IsInput().
[override virtual protected]
void CDPPropertyChannel::IssueBadDataSizeError(const char *methodName, unsigned int size)
Reimplemented from ACDPBaseChannel::IssueBadDataSizeError().
Prints an error CDPMessage because of mismatch between specified size and size of type T.
[override virtual]
const char *CDPPropertyChannel::Name() const
Reimplemented from IChannel::Name().
[override virtual]
bool CDPPropertyChannel::PutData(const void *data, unsigned int size = 0, double timestamp = 0.0)
Reimplemented from IChannel::PutData().
[override virtual]
void CDPPropertyChannel::SetChannelParameters(bool input, int moduleNo, int channelGroup, int channelNo)
Reimplemented from ICDPChannel::SetChannelParameters().
[override virtual]
void CDPPropertyChannel::SetDataPointer(void *data, double *timeStamp = nullptr, std::optional<unsigned int> size = {})
[override virtual protected]
void CDPPropertyChannel::SetExternal(T newValue)
Reimplemented from ACDPBaseChannel::SetExternal().
Sets the value of m_property
from newValue
of type T.
[override virtual protected]
void CDPPropertyChannel::SetInternal(T newValue, double timeStamp)
Reimplemented from ACDPBaseChannel::SetInternal().
m_property
is updated with newValue
, called from ACDPBaseChannel::SyncOut().
[override virtual]
void CDPPropertyChannel::SetProperty(std::string name, std::string value)
Reimplemented from ICDPChannel::SetProperty().
[override virtual]
void CDPPropertyChannel::SyncIn()
[override virtual]
void CDPPropertyChannel::SyncOut()
Member Variable Documentation
CDPProperty<T> CDPPropertyChannel::m_property
This variable holds the CDP class that facilitates the external communication with rest of cdp.
Get started with CDP Studio today
Let us help you take your great ideas and turn them into the products your customer will love.