Library: JSON
Package: JSON
Header: Poco/JSON/ParserImpl.h
Inheritance
Known Derived Classes: Parser
Member Summary
Member Functions: asVarImpl, getAllowCommentsImpl, getAllowNullByteImpl, getDepthImpl, getHandlerImpl, parseImpl, resetImpl, resultImpl, setAllowCommentsImpl, setAllowNullByteImpl, setDepthImpl, setHandlerImpl
Constructors
ParserImpl
ParserImpl(
const Handler::Ptr & pHandler = new ParseHandler
);
Creates JSON ParserImpl, using the given Handler and buffer size.
Destructor
~ParserImpl
virtual ~ParserImpl();
Destroys JSON ParserImpl.
Member Functions
asVarImpl
Dynamic::Var asVarImpl() const;
Returns the result of parsing;
getAllowCommentsImpl
bool getAllowCommentsImpl() const;
Returns true if comments are allowed, false otherwise.
By default, comments are not allowed.
getAllowNullByteImpl
bool getAllowNullByteImpl() const;
Returns true if null byte is allowed, false otherwise.
By default, null bytes are allowed.
getDepthImpl
std::size_t getDepthImpl() const;
Returns the allowed JSON depth.
getHandlerImpl
const Handler::Ptr & getHandlerImpl();
Returns the Handler.
parseImpl
Dynamic::Var parseImpl(
const std::string & json
);
Parses JSON from a string.
parseImpl
Dynamic::Var parseImpl(
std::istream & in
);
Parses JSON from an input stream.
resetImpl
void resetImpl();
Resets the parser.
resultImpl
Dynamic::Var resultImpl() const;
Returns the result of parsing as Dynamic::Var;
setAllowCommentsImpl
void setAllowCommentsImpl(
bool comments
);
Allow or disallow comments. By default, comments are not allowed.
setAllowNullByteImpl
void setAllowNullByteImpl(
bool nullByte
);
Allow or disallow null byte in strings.
By default, null byte is allowed.
setDepthImpl
void setDepthImpl(
std::size_t depth
);
Sets the allowed JSON depth.
setHandlerImpl
void setHandlerImpl(
const Handler::Ptr & pHandler
);
Set the Handler.
Variables
JSON_DEFAULT_DEPTH
static const std::size_t JSON_DEFAULT_DEPTH = 128;