peary::interface::iface_ipsocket
peary::interface::iface_ipsocket
Configuration class for IPSocket interface.
#include <peary/interfaces/IPSocket/ipsocket.hpp>
Inherits from peary::interface::Interface< ipsocket_t, ipsocket_t >
Public Functions
| Name | |
|---|---|
| virtual ipsocket_t | write(const ipsocket_t & payload) overrideWrite data to the IPSocket interface. |
| virtual dataVector_type | read(const ipsocket_t & query, const unsigned int length) overrideRead data from the IPSocket interface. |
| std::vector< uint8_t > | read_binary(const ipsocket_t & query, const unsigned int length)Read binary data from the IPSocket interface. |
| iface_ipsocket() =deleteDeleted default constructor to prevent instantiation without configuration. |
Friends
| Name | |
|---|---|
| iface_ipsocket & | InterfaceManager::getInterface(const configuration_type & ) Friend function to get an instance of iface_ipsocket from the InterfaceManager. |
| void | InterfaceManager::deleteInterface(iface_ipsocket * ) Friend function to delete an instance of iface_ipsocket from the InterfaceManager. |
Additional inherited members
Public Types inherited from peary::interface::Interface< ipsocket_t, ipsocket_t >
| Name | |
|---|---|
| using REG_T | reg_type Type aliases for register type, data type, configuration type, and data vector type. |
| using DATA_T | data_type |
| using CONFIG_T | configuration_type |
| using std::vector< data_type > | dataVector_type |
Public Functions inherited from peary::interface::Interface< ipsocket_t, ipsocket_t >
| Name | |
|---|---|
| std::string | devicePath() constGet the device path associated with the interface. |
Protected Functions inherited from peary::interface::Interface< ipsocket_t, ipsocket_t >
| Name | |
|---|---|
| Interface(const InterfaceConfiguration & config)Constructor for Interface class. | |
| virtual | ~Interface() =defaultVirtual destructor for Interface class. |
Public Functions Documentation
function write
virtual ipsocket_t write(
const ipsocket_t & payload
) override
Write data to the IPSocket interface.
Parameters:
- payload The data to be sent to the IPSocket interface
Return: The response received from the IPSocket interface
Reimplements: peary::interface::Interface::write
function read
virtual dataVector_type read(
const ipsocket_t & query,
const unsigned int length
) override
Read data from the IPSocket interface.
Parameters:
- query The query to be sent to the IPSocket interface
- length The number of bytes to read from the IPSocket interface
Return: A vector containing the data read from the IPSocket interface
Reimplements: peary::interface::Interface::read
function read_binary
std::vector< uint8_t > read_binary(
const ipsocket_t & query,
const unsigned int length
)
Read binary data from the IPSocket interface.
Parameters:
- query The query to be sent to the IPSocket interface
- length The number of bytes to read from the IPSocket interface
Return: A vector containing the binary data read from the IPSocket interface
function iface_ipsocket
iface_ipsocket() =delete
Deleted default constructor to prevent instantiation without configuration.
Friends
friend InterfaceManager::getInterface
friend iface_ipsocket & InterfaceManager::getInterface(
const configuration_type &
);
Friend function to get an instance of iface_ipsocket from the InterfaceManager.
Return: A reference to the iface_ipsocket instance
friend InterfaceManager::deleteInterface
friend void InterfaceManager::deleteInterface(
iface_ipsocket *
);
Friend function to delete an instance of iface_ipsocket from the InterfaceManager.
Updated on 2025-11-14 at 11:31:23 +0100