Inheritance diagram for zeus::BufferAnswer:
zeus::BufferParameter zeus::Buffer

Public Member Functions

enum zeus::Buffer::typeMessage getType () const override
 
template<class ZEUS_TYPE_DATA >
void addAnswer (const ZEUS_TYPE_DATA &_value)
 
template<class ZEUS_TYPE_DATA >
ZEUS_TYPE_DATA getAnswer () const
 
void addError (const std::string &_value, const std::string &_comment)
 
bool hasError () const
 
const std::string & getError () const
 
const std::string & getErrorHelp () const
 
- Public Member Functions inherited from zeus::BufferParameter
template<class ZEUS_TYPE_DATA >
ZEUS_TYPE_DATA getParameter (int32_t _id) const
 
zeus::ParamType getParameterType (int32_t _id) const
 
const uint8_t * getParameterPointer (int32_t _id) const
 
uint32_t getParameterSize (int32_t _id) const
 
uint16_t getNumberParameter () const
 
void addParameterEmptyVector ()
 
void addParameter ()
 
std::string simpleStringParam (uint32_t _id) const
 
void composeWith (const uint8_t *_buffer, uint32_t _lenght) override
 
bool writeOn (enet::WebSocket &_interface) override
 
template<class ZEUS_TYPE_DATA >
void addParameter (const ZEUS_TYPE_DATA &_value)
 
void parameterAppendBufferData (ememory::SharedPtr< zeus::BufferData > _obj)
 
- Public Member Functions inherited from zeus::Buffer
virtual ~Buffer ()=default
 
bool haveAsync () const
 
std::vector< zeus::ActionAsyncClient > moveAsync ()
 
void appendBuffer (ememory::SharedPtr< zeus::Buffer > _obj)
 
void clear ()
 
uint32_t getTransactionId () const
 
void setTransactionId (uint32_t _value)
 
uint32_t getClientId () const
 
void setClientId (uint32_t _value)
 
uint32_t getServiceId () const
 
void setServiceId (uint32_t _value)
 
bool getPartFinish () const
 
void setPartFinish (bool _value)
 

Static Public Member Functions

static ememory::SharedPtr< zeus::BufferAnswercreate ()
 
- Static Public Member Functions inherited from zeus::Buffer
static ememory::SharedPtr< zeus::Buffercreate ()
 
static ememory::SharedPtr< zeus::Buffercreate (const std::vector< uint8_t > &_buffer)
 

Protected Member Functions

 BufferAnswer ()
 
void composeWith (const uint8_t *_buffer, uint32_t _lenght) override
 
void appendBufferData (ememory::SharedPtr< zeus::BufferData > _obj) override
 
bool writeOn (enet::WebSocket &_interface) override
 
void generateDisplay (std::ostream &_os) const override
 
- Protected Member Functions inherited from zeus::BufferParameter
template<class ZEUS_TYPE_DATA >
void addParameter (uint16_t _paramId, const ZEUS_TYPE_DATA &_value)
 
- Protected Member Functions inherited from zeus::Buffer
 Buffer ()
 

Protected Attributes

std::string m_errorType
 
std::string m_errorHelp
 
- Protected Attributes inherited from zeus::BufferParameter
std::vector< std::pair< int32_t, std::vector< uint8_t > > > m_parameter
 
- Protected Attributes inherited from zeus::Buffer
headerBin m_header
 
std::vector< zeus::ActionAsyncClient > m_multipleSend
 

Friends

class zeus::Buffer
 

Additional Inherited Members

- Public Types inherited from zeus::Buffer
enum  typeMessage {
  typeMessage::unknow = 0x0000, typeMessage::call = 0x0001, typeMessage::answer = 0x0002, typeMessage::data = 0x0003,
  typeMessage::event = 0x0004
}
 

Constructor & Destructor Documentation

§ BufferAnswer()

zeus::BufferAnswer::BufferAnswer ( )
inlineprotected

basic constructor (hidden to force the use of ememory::SharedPtr) zeus::BufferAnswer::create

Member Function Documentation

§ addAnswer()

template<class ZEUS_TYPE_DATA >
void zeus::BufferAnswer::addAnswer ( const ZEUS_TYPE_DATA &  _value)
inline

set the answer of the call

Parameters
[in]_valueValue to add

§ addError()

void zeus::BufferAnswer::addError ( const std::string &  _value,
const std::string &  _comment 
)

Ann an error on the message answer.

Parameters
[in]<em>valueerror value (simple string with no space with all capital letter separaete with ''
[in]_commentHuman readable help to understand the error

§ composeWith()

void zeus::BufferAnswer::composeWith ( const uint8_t *  _buffer,
uint32_t  _lenght 
)
overrideprotectedvirtual

When receive new data form websocket, it might be added by this input (set all the frame ...)

Parameters
[in]_bufferPointer on the data to add.
[in]_lenghtnumber of octet to add.

Reimplemented from zeus::Buffer.

§ create()

static ememory::SharedPtr<zeus::BufferAnswer> zeus::BufferAnswer::create ( )
static

Create a shared pointer on the BufferAnswer.

Returns
Allocated Buffer.

§ getAnswer()

template<class ZEUS_TYPE_DATA >
ZEUS_TYPE_DATA zeus::BufferAnswer::getAnswer ( ) const
inline

get the answer value

Parameters
[in]Dataof the answer

§ getError()

const std::string& zeus::BufferAnswer::getError ( ) const

get the error value (if exist)

Returns
string of the error

§ getErrorHelp()

const std::string& zeus::BufferAnswer::getErrorHelp ( ) const

get the error help (if exist)

Returns
string of the error help

§ getType()

enum zeus::Buffer::typeMessage zeus::BufferAnswer::getType ( ) const
inlineoverridevirtual

Get the type of the buffer.

Returns
the current type of the buffer

Reimplemented from zeus::Buffer.

§ hasError()

bool zeus::BufferAnswer::hasError ( ) const

Check if the answer have an error.

Returns
status of the error.

§ writeOn()

bool zeus::BufferAnswer::writeOn ( enet::WebSocket _interface)
overrideprotectedvirtual

Write the buffer on a specific interface.

Parameters
[in]_interfacesocket to write data
Returns
true of no error appear

Reimplemented from zeus::Buffer.


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