xgboost
Classes | Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | List of all members
xgboost::JsonReader Class Reference

#include <json_io.h>

Inheritance diagram for xgboost::JsonReader:
Inheritance graph
Collaboration diagram for xgboost::JsonReader:
Collaboration graph

Classes

struct  SourceLocation
 

Public Member Functions

 JsonReader (StringView str)
 
virtual ~JsonReader ()=default
 
virtual Json Load ()
 

Protected Member Functions

void SkipSpaces ()
 
char GetNextChar ()
 
char PeekNextChar ()
 
char GetNextNonSpaceChar ()
 
char GetConsecutiveChar (char expected_char)
 
void Error (std::string msg) const
 
void Expect (char c, char got)
 
virtual Json ParseString ()
 
virtual Json ParseObject ()
 
virtual Json ParseArray ()
 
virtual Json ParseNumber ()
 
virtual Json ParseBoolean ()
 
virtual Json ParseNull ()
 
Json Parse ()
 

Protected Attributes

struct xgboost::JsonReader::SourceLocation cursor_
 
StringView raw_str_
 

Static Protected Attributes

constexpr static size_t kMaxNumLength
 

Constructor & Destructor Documentation

◆ JsonReader()

xgboost::JsonReader::JsonReader ( StringView  str)
inlineexplicit

◆ ~JsonReader()

virtual xgboost::JsonReader::~JsonReader ( )
virtualdefault

Member Function Documentation

◆ Error()

void xgboost::JsonReader::Error ( std::string  msg) const
protected

◆ Expect()

void xgboost::JsonReader::Expect ( char  c,
char  got 
)
inlineprotected

◆ GetConsecutiveChar()

char xgboost::JsonReader::GetConsecutiveChar ( char  expected_char)
inlineprotected

◆ GetNextChar()

char xgboost::JsonReader::GetNextChar ( )
inlineprotected

◆ GetNextNonSpaceChar()

char xgboost::JsonReader::GetNextNonSpaceChar ( )
inlineprotected

◆ Load()

virtual Json xgboost::JsonReader::Load ( )
virtual

Reimplemented in xgboost::UBJReader.

◆ Parse()

Json xgboost::JsonReader::Parse ( )
protected

◆ ParseArray()

virtual Json xgboost::JsonReader::ParseArray ( )
protectedvirtual

◆ ParseBoolean()

virtual Json xgboost::JsonReader::ParseBoolean ( )
protectedvirtual

◆ ParseNull()

virtual Json xgboost::JsonReader::ParseNull ( )
protectedvirtual

◆ ParseNumber()

virtual Json xgboost::JsonReader::ParseNumber ( )
protectedvirtual

◆ ParseObject()

virtual Json xgboost::JsonReader::ParseObject ( )
protectedvirtual

◆ ParseString()

virtual Json xgboost::JsonReader::ParseString ( )
protectedvirtual

◆ PeekNextChar()

char xgboost::JsonReader::PeekNextChar ( )
inlineprotected

◆ SkipSpaces()

void xgboost::JsonReader::SkipSpaces ( )
protected

Member Data Documentation

◆ cursor_

struct xgboost::JsonReader::SourceLocation xgboost::JsonReader::cursor_
protected

◆ kMaxNumLength

constexpr static size_t xgboost::JsonReader::kMaxNumLength
staticconstexprprotected
Initial value:
=
std::numeric_limits<double>::max_digits10 + 1

◆ raw_str_

StringView xgboost::JsonReader::raw_str_
protected

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