OpenVPN 3 Core Library
Loading...
Searching...
No Matches
openvpn::RenderHexByte Class Reference

#include <hexstr.hpp>

Public Member Functions

 RenderHexByte (const unsigned char byte, const bool caps=false)
 
char char1 () const
 
char char2 () const
 
const char * str2 () const
 

Private Attributes

char c [2]
 

Detailed Description

Class which Renders a single byte as hexadecimal

Definition at line 81 of file hexstr.hpp.

Constructor & Destructor Documentation

◆ RenderHexByte()

openvpn::RenderHexByte::RenderHexByte ( const unsigned char  byte,
const bool  caps = false 
)
inline

Initializes a new object

Parameters
byteUnsigned char (one byte) to be processed
capsBoolean (default false) which sets the outout to be either lower case (false) or upper case (true).

Definition at line 91 of file hexstr.hpp.

Member Function Documentation

◆ char1()

char openvpn::RenderHexByte::char1 ( ) const
inline

Definition at line 97 of file hexstr.hpp.

Here is the caller graph for this function:

◆ char2()

char openvpn::RenderHexByte::char2 ( ) const
inline

Definition at line 101 of file hexstr.hpp.

Here is the caller graph for this function:

◆ str2()

const char * openvpn::RenderHexByte::str2 ( ) const
inline

Retrieve the hexadecimal representation of the value.

Warning
The result is a non-NULL terminated string.
Returns
Returns a non-NULL terminated 2 byte string with the hexadecimal representation of the initial value. The return value is guaranteed to always be 2 bytes.

Definition at line 115 of file hexstr.hpp.

Here is the caller graph for this function:

Member Data Documentation

◆ c

char openvpn::RenderHexByte::c[2]
private

Definition at line 121 of file hexstr.hpp.


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