btp_layer Class Reference

This class provides description of ITS BTP protocol layer. More...

`#include <btp_layer.hh>`

Inheritance diagram for btp_layer:

## Public Member Functions

| btp_layer ()
| Set to true if the BTP layer shall encapsulate the upper layer PDU. More...
| btp_layer (const std::string &p_type, const std::string &param)
| Specialised constructor Create a new instance of the btp_layer class. More...
virtual | ~btp_layer ()
void | sendMsg (const LibItsBtp__TestSystem::BtpReq &p_btp_req, Params &p_param)
| Send BTP message to the lower layers. More...
virtual void | send_data (OCTETSTRING &data, Params &params)
| Send bytes formated data to the lower layers. More...
virtual void | receive_data (OCTETSTRING &data, Params &info)
| Receive bytes formated data from the lower layers. More...
Public Member Functions inherited from t_layer< LibItsBtp__TestSystem::BtpPort >
| t_layer ()
| The list of the upper ports. More...
| t_layer (const std::string &p_type)
| Specialized constructor Create a new instance of the layer class with its type description. More...
void | add_upper_port (LibItsBtp__TestSystem::BtpPort *p_port)
| Add a new upper port layer. More...
void | remove_upper_port (LibItsBtp__TestSystem::BtpPort *)
| Remove the specified upper layer port protocol from the list of the upper layers. More...
Public Member Functions inherited from layer
| layer ()
| Type description, it indicates the protocol type (e.g. CAM, DENM, GN, ETH, PCAP...) More...
| layer (const std::string &p_type)
| Specialized constructor Create a new instance of the layer class with its type description. More...
virtual | ~layer ()
| Default destructor. More...
void | delete_layer ()
| Delete this layer. More...
void | add_upper_layer (layer *p_layer)
| Add a new layer in the list of the upper layer. More...
void | remove_upper_layer (layer *p_layer)
| Remove the specified upper layer protocol from the list of the upper layer. More...
const std::string & | to_string () const
| Remove the specified upper layer protocol from the list of the upper layer. More...

## Private Attributes

Params | _params
BTPCodec | _codec
| Layer parameters. More...
bool | _device_mode
| BTP codec. More...

## Additional Inherited Members

Protected Member Functions inherited from t_layer< LibItsBtp__TestSystem::BtpPort >
void | to_all_upper_ports (const TMessage &p_message, const Params &p_params)
| Forward the message to all available upper port layers. More...
Protected Member Functions inherited from layer
void | to_all_layers (std::vector< layer *> &layers, OCTETSTRING &data, Params &params)
void | receive_to_all_layers (OCTETSTRING &data, Params &params)
void | send_to_all_layers (OCTETSTRING &data, Params &params)
Protected Attributes inherited from layer
std::string | type
| List of the lower protocol layers. More...

## Detailed Description

This class provides description of ITS BTP protocol layer.

## Constructor & Destructor Documentation

## btp_layer() [1/2]

btp_layer::btp_layer | ( |  | ) |

inlineexplicit

Set to true if the BTP layer shall encapsulate the upper layer PDU.

Default constructor Create a new instance of the btp_layer class

## btp_layer() [2/2]

btp_layer::btp_layer | ( | const std::string & | p_type,
|  | const std::string & | param
| ) |  |

Specialised constructor Create a new instance of the btp_layer class.

Parameters

  [in] | p_type |

## ~btp_layer()

virtual btp_layer::~btp_layer | ( |  | ) |

inlinevirtual

## Member Function Documentation

## receive_data()

void btp_layer::receive_data | ( | OCTETSTRING & | data,
|  | Params & | params
| ) |  |

virtual

Receive bytes formated data from the lower layers.

Parameters

  [in] | p_data | The bytes formated data received
  [in] | p_params | Some lower layers parameters values when data was received

Reimplemented from layer.

## send_data()

void btp_layer::send_data | ( | OCTETSTRING & | data,
|  | Params & | params
| ) |  |

virtual

Send bytes formated data to the lower layers.

Parameters

  [in] | p_data | The data to be sent
  [in] | p_params | Some parameters to overwrite default value of the lower layers parameters

Reimplemented from layer.

## sendMsg()

void btp_layer::sendMsg | ( | const LibItsBtp__TestSystem::BtpReq & | p_btp_req,
|  | Params & | p_param
| ) |  |

Send BTP message to the lower layers.

Parameters

  [in] | p_btp_req | The BTP message to be sent
  [in] | p_params | Some parameters to overwrite default value of the lower layers parameters

## Member Data Documentation

## _codec

BTPCodec btp_layer::_codec

private

Layer parameters.

## _device_mode

bool btp_layer::_device_mode

private

BTP codec.

## _params

Params btp_layer::_params

private

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

- /home/vagrant/TriesAndDelete/etsi_its/framework/include/btp_layer.hh
- /home/vagrant/TriesAndDelete/etsi_its/framework/src/btp_layer.cc