MetaSoul

Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | List of all members
emoshapeio::packet Class Reference

`#include <sio_packet.h>`

## Public Types
enum | frame_type { frame_open = 0 , frame_close = 1 , frame_ping = 2 , frame_pong = 3 , frame_message = 4 , frame_upgrade = 5 , frame_noop = 6 }
enum | type { type_min = 0 , type_connect = 0 , type_disconnect = 1 , type_event = 2 , type_ack = 3 , type_error = 4 , type_binary_event = 5 , type_binary_ack = 6 , type_max = 6 , type_undetermined = 0x10 }

## Public Member Functions
| packet (string const &nsp, message::ptr const &msg, int pack_id=-1, bool isAck=false)
| packet (frame_type frame)
| packet (type type, string const &nsp=string(), message::ptr const &msg=message::ptr())
| packet ()
frame_type | get_frame () const
type | get_type () const
bool | parse (string const &payload_ptr)
bool | parse_buffer (string const &buf_payload)
bool | accept (string &payload_ptr, vector< shared_ptr< const string > > &buffers)
string const & | get_nsp () const
message::ptr const & | get_message () const
unsigned | get_pack_id () const

## Static Public Member Functions
static bool | is_message (string const &payload_ptr)
static bool | is_text_message (string const &payload_ptr)
static bool | is_binary_message (string const &payload_ptr)

## Member Enumeration Documentation

## ◆ frame_type

enum emoshapeio::packet::frame_type

Enumerator
frame_open |
frame_close |
frame_ping |
frame_pong |
frame_message |
frame_upgrade |
frame_noop |

## ◆ type

enum emoshapeio::packet::type

Enumerator
type_min |
type_connect |
type_disconnect |
type_event |
type_ack |
type_error |
type_binary_event |
type_binary_ack |
type_max |
type_undetermined |

## Constructor & Destructor Documentation

## ◆ packet() [1/4]

emoshapeio::packet::packet | ( | string const & | nsp,
|  | message::ptr const & | msg,
|  | int | pack_id = -1,
|  | bool | isAck = false )

## ◆ packet() [2/4]

emoshapeio::packet::packet | ( | packet::frame_type | frame | ) |

## ◆ packet() [3/4]

emoshapeio::packet::packet | ( | type | type,
|  | string const & | nsp = string(),
|  | message::ptr const & | msg = message::ptr() )

## ◆ packet() [4/4]

emoshapeio::packet::packet | ( |  | ) |

## Member Function Documentation

## ◆ accept()

bool emoshapeio::packet::accept | ( | string & | payload_ptr,
|  | vector< shared_ptr< const string > > & | buffers )

## ◆ get_frame()

packet::frame_type emoshapeio::packet::get_frame | ( |  | ) | const

## ◆ get_message()

message::ptr const & emoshapeio::packet::get_message | ( |  | ) | const

## ◆ get_nsp()

string const & emoshapeio::packet::get_nsp | ( |  | ) | const

## ◆ get_pack_id()

unsigned emoshapeio::packet::get_pack_id | ( |  | ) | const

## ◆ get_type()

packet::type emoshapeio::packet::get_type | ( |  | ) | const

## ◆ is_binary_message()

bool emoshapeio::packet::is_binary_message | ( | string const & | payload_ptr | ) |
| static

## ◆ is_message()

bool emoshapeio::packet::is_message | ( | string const & | payload_ptr | ) |
| static

## ◆ is_text_message()

bool emoshapeio::packet::is_text_message | ( | string const & | payload_ptr | ) |
| static

## ◆ parse()

bool emoshapeio::packet::parse | ( | string const & | payload_ptr | ) |

## ◆ parse_buffer()

bool emoshapeio::packet::parse_buffer | ( | string const & | buf_payload | ) |

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

- EmoShapeIOLib/Private/internal/sio_packet.h
- EmoShapeIOLib/Private/internal/sio_packet.cpp