xgboost
Public Types | Public Member Functions | Static Public Member Functions | List of all members
xgboost::JsonInteger Class Reference

#include <json.h>

Inheritance diagram for xgboost::JsonInteger:
Inheritance graph
Collaboration diagram for xgboost::JsonInteger:
Collaboration graph

Public Types

using Int = int64_t
 
- Public Types inherited from xgboost::Value
enum class  ValueKind {
  kString , kNumber , kInteger , kObject ,
  kArray , kBoolean , kNull , kNumberArray ,
  kU8Array , kI32Array , kI64Array
}
 Simplified implementation of LLVM RTTI. More...
 

Public Member Functions

 JsonInteger ()
 
template<typename IntT , typename std::enable_if< std::is_same< IntT, Int >::value >::type * = nullptr>
 JsonInteger (IntT value)
 
template<typename IntT , typename std::enable_if< std::is_same< IntT, size_t >::value >::type * = nullptr>
 JsonInteger (IntT value)
 
template<typename IntT , typename std::enable_if< std::is_same< IntT, int32_t >::value >::type * = nullptr>
 JsonInteger (IntT value)
 
template<typename IntT , typename std::enable_if< std::is_same< IntT, uint32_t >::value &&!std::is_same< std::size_t, uint32_t >::value >::type * = nullptr>
 JsonInteger (IntT value)
 
 JsonInteger (JsonInteger &&that) noexcept
 
bool operator== (Value const &rhs) const override
 
Int const & GetInteger () &&
 
Int const & GetInteger () const &
 
IntGetInteger () &
 
void Save (JsonWriter *writer) const override
 
- Public Member Functions inherited from xgboost::Value
 Value (ValueKind _kind)
 
ValueKind Type () const
 
virtual ~Value ()=default
 
virtual Jsonoperator[] (std::string const &key)
 
virtual Jsonoperator[] (int ind)
 
virtual Valueoperator= (Value const &rhs)=delete
 
std::string TypeStr () const
 

Static Public Member Functions

static bool IsClassOf (Value const *value)
 

Member Typedef Documentation

◆ Int

using xgboost::JsonInteger::Int = int64_t

Constructor & Destructor Documentation

◆ JsonInteger() [1/6]

xgboost::JsonInteger::JsonInteger ( )
inline

◆ JsonInteger() [2/6]

template<typename IntT , typename std::enable_if< std::is_same< IntT, Int >::value >::type * = nullptr>
xgboost::JsonInteger::JsonInteger ( IntT  value)
inline

◆ JsonInteger() [3/6]

template<typename IntT , typename std::enable_if< std::is_same< IntT, size_t >::value >::type * = nullptr>
xgboost::JsonInteger::JsonInteger ( IntT  value)
inline

◆ JsonInteger() [4/6]

template<typename IntT , typename std::enable_if< std::is_same< IntT, int32_t >::value >::type * = nullptr>
xgboost::JsonInteger::JsonInteger ( IntT  value)
inline

◆ JsonInteger() [5/6]

template<typename IntT , typename std::enable_if< std::is_same< IntT, uint32_t >::value &&!std::is_same< std::size_t, uint32_t >::value >::type * = nullptr>
xgboost::JsonInteger::JsonInteger ( IntT  value)
inline

◆ JsonInteger() [6/6]

xgboost::JsonInteger::JsonInteger ( JsonInteger &&  that)
inlinenoexcept

Member Function Documentation

◆ GetInteger() [1/3]

Int& xgboost::JsonInteger::GetInteger ( ) &
inline

◆ GetInteger() [2/3]

Int const& xgboost::JsonInteger::GetInteger ( ) &&
inline

◆ GetInteger() [3/3]

Int const& xgboost::JsonInteger::GetInteger ( ) const &
inline

◆ IsClassOf()

static bool xgboost::JsonInteger::IsClassOf ( Value const *  value)
inlinestatic

◆ operator==()

bool xgboost::JsonInteger::operator== ( Value const &  rhs) const
overridevirtual

Implements xgboost::Value.

◆ Save()

void xgboost::JsonInteger::Save ( JsonWriter writer) const
overridevirtual

Implements xgboost::Value.


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