Direct-BT v3.3.0-1-gc2d430c
Direct-BT - Direct Bluetooth Programming.
Public Member Functions | Protected Member Functions | List of all members
direct_bt::HCIStructCommand< hcistruct > Class Template Reference

Generic HCICommand wrapper for any HCI IOCTL structure. More...

#include <HCITypes.hpp>

Inheritance diagram for direct_bt::HCIStructCommand< hcistruct >:
Collaboration diagram for direct_bt::HCIStructCommand< hcistruct >:

Public Member Functions

 HCIStructCommand (const HCIOpcode opc)
 Enabling manual construction of command with zero value. More...
 
 HCIStructCommand (const HCIOpcode opc, const hcistruct &cp)
 Enabling manual construction of command with given value. More...
 
const hcistruct * getStruct () const noexcept
 
hcistruct * getWStruct () noexcept
 
- Public Member Functions inherited from direct_bt::HCICommand
 HCICommand (const HCIOpcode opc, const jau::nsize_t param_size)
 Enabling manual construction of command without given value. More...
 
 HCICommand (const HCIOpcode opc, const uint8_t *param, const jau::nsize_t param_size)
 Enabling manual construction of command with given value. More...
 
 HCICommand (const uint8_t *buffer, const jau::nsize_t buffer_len, const jau::nsize_t exp_param_size)
 Persistent memory, w/ ownership . More...
 
 ~HCICommand () noexcept override=default
 
HCIOpcode getOpcode () const noexcept
 
const uint8_t * getParam () const noexcept
 
jau::nsize_t getParamSize () const noexcept
 
void trimParamSize (const jau::nsize_t param_size)
 
- Public Member Functions inherited from direct_bt::HCIPacket
 HCIPacket (const HCIPacketType type, const jau::nsize_t total_packet_size)
 
 HCIPacket (const uint8_t *packet_data, const jau::nsize_t total_packet_size)
 Persistent memory, w/ ownership . More...
 
virtual ~HCIPacket () noexcept=default
 
HCIPacketType getPacketType () noexcept
 
jau::TROOctetsgetPDU () noexcept
 Return the underlying octets read only. More...
 
constexpr jau::nsize_t getTotalSize () const noexcept
 
std::string toString () const noexcept
 

Protected Member Functions

std::string nameString () const noexcept override
 
- Protected Member Functions inherited from direct_bt::HCICommand
std::string baseString () const noexcept override
 
std::string nameString () const noexcept override
 
std::string valueString () const noexcept override
 
virtual std::string baseString () const noexcept
 
virtual std::string nameString () const noexcept
 
virtual std::string valueString () const noexcept
 

Additional Inherited Members

- Static Public Member Functions inherited from direct_bt::HCICommand
static std::unique_ptr< HCICommandgetSpecialized (const uint8_t *buffer, jau::nsize_t const buffer_size) noexcept
 Return a newly created specialized instance pointer to base class. More...
 
- Static Public Member Functions inherited from direct_bt::HCIPacket
template<class T >
static T * clone (const T &source) noexcept
 Clone template for convenience, based on derived class's copy-constructor. More...
 
- Static Protected Member Functions inherited from direct_bt::HCICommand
static void checkOpcode (const HCIOpcode has, const HCIOpcode exp)
 
static void checkOpcode (const HCIOpcode has, const HCIOpcode min, const HCIOpcode max)
 
- Static Protected Member Functions inherited from direct_bt::HCIPacket
static void checkPacketType (const HCIPacketType type)
 
- Protected Attributes inherited from direct_bt::HCIPacket
jau::POctets pdu
 

Detailed Description

template<typename hcistruct>
class direct_bt::HCIStructCommand< hcistruct >

Generic HCICommand wrapper for any HCI IOCTL structure.

Template Parameters
hcistructthe template typename, e.g. 'hci_cp_create_conn' for 'struct hci_cp_create_conn'

Definition at line 928 of file HCITypes.hpp.

Constructor & Destructor Documentation

◆ HCIStructCommand() [1/2]

template<typename hcistruct >
direct_bt::HCIStructCommand< hcistruct >::HCIStructCommand ( const HCIOpcode  opc)
inline

Enabling manual construction of command with zero value.

Definition at line 935 of file HCITypes.hpp.

◆ HCIStructCommand() [2/2]

template<typename hcistruct >
direct_bt::HCIStructCommand< hcistruct >::HCIStructCommand ( const HCIOpcode  opc,
const hcistruct &  cp 
)
inline

Enabling manual construction of command with given value.


Definition at line 943 of file HCITypes.hpp.

Member Function Documentation

◆ nameString()

template<typename hcistruct >
std::string direct_bt::HCIStructCommand< hcistruct >::nameString ( ) const
inlineoverrideprotectedvirtualnoexcept

Reimplemented from direct_bt::HCICommand.

Definition at line 931 of file HCITypes.hpp.

◆ getStruct()

template<typename hcistruct >
const hcistruct * direct_bt::HCIStructCommand< hcistruct >::getStruct ( ) const
inlinenoexcept

Definition at line 947 of file HCITypes.hpp.

◆ getWStruct()

template<typename hcistruct >
hcistruct * direct_bt::HCIStructCommand< hcistruct >::getWStruct ( )
inlinenoexcept

Definition at line 948 of file HCITypes.hpp.

Here is the caller graph for this function:

The documentation for this class was generated from the following file: