aes70::device class
Contents
- Reference
Pure virtual device subclass.
Public functions
- auto receive(connection& connection, const uint8_t* src, const uint8_t* src_end) -> AES70_WARN_UNUSED_RESULT std::tuple<const uint8_t*, bool> pure virtual
-
auto allocate_property_changed_notification(uint32_t ono,
const OcaPropertyID& prop,
size_t len,
OcaPropertyChangeType type = OcaPropertyChangeType::
CurrentChanged) -> uint8_t* - void send_property_changed_notification(uint32_t ono, size_t len)
- auto add_connection(connection* connection) -> bool pure virtual
- auto remove_connection(connection* connection) -> bool pure virtual
- auto find_connection(size_t id) -> connection* pure virtual
- auto first_connection() const -> connection* pure virtual
- void close() pure virtual
-
auto cork_handle() -> AES70_WARN_UNUSED_RESULT aes70::
cork_handle<device> - void uncork() pure virtual
- void cork() pure virtual
-
void call_in(uint32_t object_number,
const OcaMethodID id,
const uint8_t* src,
const uint8_t* src_end,
const aes70::
response_generator& response) pure virtual
Function documentation
AES70_WARN_UNUSED_RESULT std::tuple<const uint8_t*, bool> aes70:: device:: receive(connection& connection,
const uint8_t* src,
const uint8_t* src_end) pure virtual
Receive incoming data on the given connection.
uint8_t* aes70:: device:: allocate_property_changed_notification(uint32_t ono,
const OcaPropertyID& prop,
size_t len,
OcaPropertyChangeType type = OcaPropertyChangeType:: CurrentChanged)
Allocate a property change notification and reserve len bytes for the value of the property.
Call send_property_changed_notification to send the notification.
void aes70:: device:: send_property_changed_notification(uint32_t ono,
size_t len)
Sends a property_change_notification previously allocated with allocate_property_changed_notification.
bool aes70:: device:: add_connection(connection* connection) pure virtual
Adds a new connection to this device. Returns true on success and false if the connection could not be added, e.g. due to resource limits having been reached.
bool aes70:: device:: remove_connection(connection* connection) pure virtual
Removes a connection. Returns true if the connection has been removed and false if not, e.g. because it was not found.
connection* aes70:: device:: find_connection(size_t id) pure virtual
Find a connection given its id.
connection* aes70:: device:: first_connection() const pure virtual
Returns one connection. Returns nullptr if there is no connected connection, anymore. Useful for closing all connections.
void aes70:: device:: close() pure virtual
Close all AES70 connections of this device.
AES70_WARN_UNUSED_RESULT aes70:: cork_handle<device> aes70:: device:: cork_handle()
Calls cork. uncork is called automatically when the returned handle goes out of scope.
void aes70:: device:: uncork() pure virtual
Calls connection::
void aes70:: device:: cork() pure virtual
Calls connection::
void aes70:: device:: call_in(uint32_t object_number,
const OcaMethodID id,
const uint8_t* src,
const uint8_t* src_end,
const aes70:: response_generator& response) pure virtual
Calls method with given id in object with given number.