libzypp: zypp-core/parser/json.h File Reference

libzypp 17.38.15

json.h File Reference

Public JSON API. More...

`#include <zypp-core/Globals.h>`
`#include <zypp-core/base/InputStream>`
`#include <zypp-core/parser/parseexception.h>`
`#include "json/JsonValue.h"`

Go to the source code of this file.

## Namespaces
namespace | zypp
| Easy-to use interface to the ZYPP dependency resolver.
namespace | zypp::json

## Functions
Value | zypp::json::parseDocument (const InputStream &input_r)
| Parse a JSON document from input_r.

## Detailed Description

Public JSON API.

External consumers (compiling without -DZYPP_DLL) see only:

- zypp::json::Value, Object, Array and their supporting types
- zypp::json::parseDocument() — throws parser::ParseException on error

Code compiling as part of libzypp (-DZYPP_DLL) additionally gets:

- zypp::json::parseDocumentExpected() — NG-style expected<Value> return
- zypp::json::detail::Parser (via json/private/jsonparser_p.h) for direct tokeniser use

Definition in file json.h.