...
The VictorMockDeviceManager manages all mock VictoR device connection interfaces through VictorMockDevice objects that it creates, maintains, and destroys as needed. This class acts as the primary interface for end-users to “discover” (create) mock devices and manage connections to them. In addition, the VictorMockDeviceManager provides a wrapper around the functions that the VictorMockDevice class offers, requiring only that the end-user provide the ID for the specific mock device that they are interested in interacting with, so that they don’t need to have any knowledge of the underlying organization of the devices within the manager. The class diagram in Figure 1 illustrates the architecture of the Mock Communications API.
...
VictorMockDevice
VictorMockDevice represents an “internal” device, i.e. it is simply a data structure containing data fields (“attributes”, “characteristics”) that can be read from/written to, held in system memory.
...
Writes the given data to the specified attribute
Attribute and data is stored as a dictionary of UUID to byte arrays
Where possible, byte array size will adhere to the specifications stated in the ICD
Triggers all callbacks associated with the specified attribute
SubscribeSubscribeAttributeChange
Creates the specified attribute if such attribute does not already exist in the mock device
Register the given callback by adding it to the association table
UnsubscribeUnsubscribeAttributeChange
Deregister the given callback by removing it from the association table
...
Removes device from dictionary
GetConnectedDeviceIDsGetConnectedDevices
Returns a list of IDs VictorDeviceInfos of connected devices from connected device dictionary
...