aes70::device::device class

Contents

Pure virtual device subclass.

Public functions

auto allocate_notifications(const OcaEvent& id, size_t len, uint8_t parameterCount) -> uint8_t* pure virtual
void send_notifications(const OcaEvent& id, size_t len, uint8_t parameterCount) 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 get_parent_ono(uint32_t ono) -> uint32_t pure virtual
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
auto has_event(const OcaEvent event) const -> bool pure virtual
void call_in(uint32_t object_number, const OcaMethodID id, const uint8_t* src, const uint8_t* src_end, uint8_t parameterCount, const aes70::device::response_generator_tmpl<connection>& response) pure virtual

Function documentation

uint8_t* aes70::device::device::allocate_notifications(const OcaEvent& id, size_t len, uint8_t parameterCount) pure virtual

Allocate send buffer space for sending notifications. Returns nullptr if no connection has subscribed to the given event.

void aes70::device::device::send_notifications(const OcaEvent& id, size_t len, uint8_t parameterCount) pure virtual

Allocate send buffer space for sending notifications. Returns nullptr if no connection has subscribed to the given event.

uint8_t* aes70::device::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::device::send_property_changed_notification(uint32_t ono, size_t len)

Sends a property_change_notification previously allocated with allocate_property_changed_notification.

uint32_t aes70::device::device::get_parent_ono(uint32_t ono) pure virtual

Returns the object number of the parent of a given object. Returns 0 for managers and the root block.

bool aes70::device::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::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::device::find_connection(size_t id) pure virtual

Find a connection given its id.

connection* aes70::device::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::device::close() pure virtual

Close all AES70 connections of this device.

AES70_WARN_UNUSED_RESULT aes70::cork_handle<device> aes70::device::device::cork_handle()

Calls cork. uncork is called automatically when the returned handle goes out of scope.

void aes70::device::device::uncork() pure virtual

Calls connection::uncork on all active connections.

void aes70::device::device::cork() pure virtual

Calls connection::cork on all active connections.

bool aes70::device::device::has_event(const OcaEvent event) const pure virtual

Returns true of this device has the given event.

void aes70::device::device::call_in(uint32_t object_number, const OcaMethodID id, const uint8_t* src, const uint8_t* src_end, uint8_t parameterCount, const aes70::device::response_generator_tmpl<connection>& response) pure virtual

Calls method with given id in object with given number.