JSON reader context.
More...
#include <readerContext.hpp>
JSON reader context.
Context is used to store mapping options and deserialization buffers
- Author
- Vincent Lachenal
- Since
- 0.1
◆ ReaderContext() [1/4]
| anch::json::ReaderContext::ReaderContext |
( |
| ) |
|
|
delete |
◆ ReaderContext() [2/4]
| anch::json::ReaderContext::ReaderContext |
( |
const ReaderContext & | context | ) |
|
|
delete |
Forbids ReaderContext copy constructor
- Parameters
-
| context | the context not to copy |
◆ ReaderContext() [3/4]
| anch::json::ReaderContext::ReaderContext |
( |
ReaderContext && | context | ) |
|
|
delete |
Forbids ReaderContext move constructor
- Parameters
-
| context | the context not to move |
◆ ReaderContext() [4/4]
ReaderContext constructor
- Parameters
-
| is | the input stream to read |
| options | the mapping options to use |
◆ ~ReaderContext()
| virtual anch::json::ReaderContext::~ReaderContext |
( |
| ) |
|
|
virtualnoexcept |
◆ back()
| void anch::json::ReaderContext::back |
( |
| ) |
|
Go to previous character.
◆ discard()
| char anch::json::ReaderContext::discard |
( |
| ) |
|
Discard character until found undiscardable character or fail according to options
- Returns
- the next undiscardable character
- Exceptions
-
◆ next()
| bool anch::json::ReaderContext::next |
( |
char & | current | ) |
|
Get next character in buffer.
If buffer has reached its end, it will refill buffer with the input stream.
- Parameters
-
| current | the character to write in |
- Returns
true if buffer end has been reached
- Exceptions
-
◆ parseUnknown()
| void anch::json::ReaderContext::parseUnknown |
( |
| ) |
|
Parse unknown value or fail according to options
- Exceptions
-
◆ refillBuffer()
| virtual std::streamsize anch::json::ReaderContext::refillBuffer |
( |
| ) |
|
|
protectedvirtual |
◆ buffer
| char* anch::json::ReaderContext::buffer |
◆ bufferSize
| std::size_t anch::json::ReaderContext::bufferSize |
Parser buffer size (default to 1024)
◆ input
| std::istream& anch::json::ReaderContext::input |
The input stream to parse
◆ offset
| uint32_t anch::json::ReaderContext::offset |
◆ options
◆ pbuf
| std::string anch::json::ReaderContext::pbuf |
◆ read
| std::size_t anch::json::ReaderContext::read |
Global number of read characters
The documentation for this class was generated from the following file: