xgboost
| 公共类型 | 公共成员函数 | 保护成员函数 | 保护属性 | 静态保护属性 | 所有成员列表
xgboost::JsonReader 类参考

一个 JSON 读取器,目前错误检查和 UTF-8 尚未完全支持。更多...

#include <json_io.h>

xgboost::JsonReader 的继承图
Inheritance graph
xgboost::JsonReader 的协作图
Collaboration graph

结构  SourceLocation
 

公共类型

使用 Char = std::int8_t
 

公共成员函数

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

保护成员函数

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 ()
 

保护属性

struct xgboost::JsonReader::SourceLocation cursor_
 
StringView raw_str_
 

静态保护属性

constexpr static size_t kMaxNumLength = std::numeric_limits<double>::max_digits10 + 1
 

详细描述

一个 json 读取器,目前错误检查和 utf-8 尚未完全支持。

成员类型定义文档

◆ Char

using xgboost::JsonReader::Char = std::int8_t

构造函数和析构函数文档

◆ JsonReader()

xgboost::JsonReader::JsonReader ( StringView  字符串)
内联显式

◆ ~JsonReader()

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

成员函数文档

◆ 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

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

成员数据文档

◆ cursor_

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

◆ kMaxNumLength

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

◆ raw_str_

StringView xgboost::JsonReader::raw_str_
protected

此类的文档由以下文件生成