CDC Badge OS
Firmware for the CDC Badge v1.0 hardware security key
Loading...
Searching...
No Matches
ServiceRegistry.h File Reference
#include "IService.h"
#include <cstddef>

Go to the source code of this file.

Classes

class  cdc::core::ServiceRegistry

Namespaces

namespace  cdc
namespace  cdc::core

Macros

#define CDC_SERVICE(type, name)
#define CDC_PROVIDE_SERVICE(type, ptr)
#define CDC_REQUEST_SERVICE(type, T)

Enumerations

enum class  cdc::core::ServiceType { cdc::core::KEYBOARD , cdc::core::CHALLENGE_RESPONDER , cdc::core::CLIPBOARD , cdc::core::NOTIFICATION }

Macro Definition Documentation

◆ CDC_PROVIDE_SERVICE

#define CDC_PROVIDE_SERVICE ( type,
ptr )
Value:
cdc::core::ServiceRegistry::instance().provide<decltype(*(ptr))>(type, ptr)
bool provide(ServiceType type, T *service)
static ServiceRegistry & instance()
Returns singleton service registry instance.

Definition at line 147 of file ServiceRegistry.h.

◆ CDC_REQUEST_SERVICE

#define CDC_REQUEST_SERVICE ( type,
T )
Value:

Definition at line 150 of file ServiceRegistry.h.

◆ CDC_SERVICE

#define CDC_SERVICE ( type,
name )
Value:
char name[cdc::hal::ISecureElement::RMEM_NAME_LEN]
T * get(const char *name)

Definition at line 144 of file ServiceRegistry.h.