GameApi 28
Library used by GameApi Builder tool
Loading...
Searching...
No Matches
ChaiScript_Language::Object Class Reference

Generic concept of a value in ChaiScript. More...

#include <chaiscript_prelude_docs.hpp>

Public Member Functions

Type_Info get_type_info () const
 Returns the Type_Info value for this Object.
bool is_type (string) const
 Returns true if the Object is of the named type.
bool is_type (Type_Info) const
 Returns true if the Object is of the Type_Info passed in.
bool is_var_const () const
 Returns true if the Object is immutable.
bool is_var_null () const
 Returns true if the Object is a pointer and the pointer is null.
bool is_var_pointer () const
 Returns true if the Object is stored as a pointer.
bool is_var_reference () const
 Returns true if the Object is stored as a reference.
bool is_var_undef () const
 Returns true if the Object does not contain a value is is undefined.
string type_name () const
 Returns the registered name of the type of the object.

Detailed Description

Generic concept of a value in ChaiScript.

The Object type exists merely as a concept. All objects in ChaiScript support this concept and have the following methods available to them. All objects are stored internally as chaiscript::Boxed_Value types.

See also
chaiscript::Boxed_Value

Member Function Documentation

◆ get_type_info()

Type_Info ChaiScript_Language::Object::get_type_info ( ) const

Returns the Type_Info value for this Object.

◆ is_type() [1/2]

bool ChaiScript_Language::Object::is_type ( string ) const

Returns true if the Object is of the named type.

◆ is_type() [2/2]

bool ChaiScript_Language::Object::is_type ( Type_Info ) const

Returns true if the Object is of the Type_Info passed in.

◆ is_var_const()

bool ChaiScript_Language::Object::is_var_const ( ) const

Returns true if the Object is immutable.

◆ is_var_null()

bool ChaiScript_Language::Object::is_var_null ( ) const

Returns true if the Object is a pointer and the pointer is null.

◆ is_var_pointer()

bool ChaiScript_Language::Object::is_var_pointer ( ) const

Returns true if the Object is stored as a pointer.

◆ is_var_reference()

bool ChaiScript_Language::Object::is_var_reference ( ) const

Returns true if the Object is stored as a reference.

◆ is_var_undef()

bool ChaiScript_Language::Object::is_var_undef ( ) const

Returns true if the Object does not contain a value is is undefined.

◆ type_name()

string ChaiScript_Language::Object::type_name ( ) const

Returns the registered name of the type of the object.

See also
Type_Info::name();

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