![]() |
PIP 5.6.1
Platform-Independent Primitives
|
Configuration for PIStreamPacker packet framing. More...
#include <pistreampacker.h>

Public Member Functions | |
| PIStreamPackerConfig () | |
| Constructs configuration with default packet framing parameters. | |
| void | setMaxPacketSize (int max_size) |
| Sets maximum size of one emitted frame chunk. | |
| int | maxPacketSize () const |
| Returns maximum size of one emitted frame chunk. | |
| void | setPacketSign (ushort sign_) |
| Sets packet signature used to detect frame boundaries. | |
| ushort | packetSign () const |
| Returns packet signature. | |
| void | setaAggressiveOptimization (bool yes) |
| Enables faster resynchronization on invalid stream data. More... | |
| bool | aggressiveOptimization () const |
| Returns whether aggressive resynchronization is enabled. | |
| bool | cryptSizeEnabled () const |
| Returns whether packet size field is encrypted too. | |
| void | setCryptSizeEnabled (bool on) |
| Enables or disables encryption of the packet size field. | |
| const PIStreamPackerConfig & | configuration () const |
| Returns configuration as a const self-reference. | |
| PIStreamPackerConfig & | configuration () |
| Returns configuration as a mutable self-reference. | |
| void | setConfiguration (const PIStreamPackerConfig &config) |
| Replaces current framing configuration with "config". | |
Public Member Functions inherited from PIEthUtilBase | |
| PIEthUtilBase () | |
| Constructs helper with crypt layer disabled. | |
| ~PIEthUtilBase () | |
| Destroys the crypt helper. | |
| void | setCryptEnabled (bool on) |
| Enables or disables the crypt layer. | |
| void | cryptEnable () |
| Enables the crypt layer. | |
| void | cryptDisable () |
| Disables the crypt layer. | |
| bool | isCryptEnabled () const |
| Returns whether the crypt layer is enabled. | |
| void | setCryptKey (const PIByteArray &k) |
| Sets crypt key "k" and enables the crypt layer. | |
| void | createCryptKey (const PIString &k) |
| Generates crypt key from passphrase "k" and enables the crypt layer. | |
| PIByteArray | cryptKey () const |
| Returns current crypt key. | |
Additional Inherited Members | |
Static Public Member Functions inherited from PIEthUtilBase | |
| static size_t | cryptSizeAddition () |
| Returns extra size added by encryption. | |
Protected Member Functions inherited from PIEthUtilBase | |
| PIByteArray | cryptData (const PIByteArray &data) |
| Encrypts "data" when the crypt layer is enabled. | |
| PIByteArray | decryptData (const PIByteArray &data) |
| Decrypts "data" when the crypt layer is enabled. More... | |
Configuration for PIStreamPacker packet framing.
|
inline |
Enables faster resynchronization on invalid stream data.
When enabled, PIStreamPacker drops the whole current read chunk after a signature mismatch instead of scanning byte by byte.