nngn
Loading...
Searching...
No Matches
nngn::lua::global_table Class Reference

Table interface to the global environment. More...

#include <table.h>

Inheritance diagram for nngn::lua::global_table:
Collaboration diagram for nngn::lua::global_table:

Public Member Functions

 global_table ()=default
 
 global_table (const global_table &)=default
 
global_tableoperator= (const global_table &)=default
 
 global_table (global_table &&) noexcept=default
 
global_tableoperator= (global_table &&) noexcept=default
 
 global_table (state_view lua)
 
 ~global_table (void)=default
 
state_view state (void) const
 
int push (void) const
 
- Public Member Functions inherited from nngn::lua::detail::table_base< global_table >
table_proxy< global_table, std::decay_t< K > > operator[] (K &&k) const
 
lua_Integer size (void) const
 
table_iter< const global_tablebegin (void) const
 lua_next-based iteration.
 
table_iter< const global_tableend (void) const
 Sentinel for begin.
 
table_seq_iter< const global_tableibegin (void) const
 ipairs-style iteration.
 
table_seq_iter< const global_tableiend (void) const
 Sentinel for ibegin.
 
T raw_get (auto &&k, T &&def=T{}) const
 Gets field without meta methods.
 
T get_field (auto &&k, T &&def=T{}) const
 Gets field, with optional default value.
 
void raw_set (auto &&k, auto &&v) const
 Sets a table field without meta methods.
 
void set (auto &&k, auto &&v) const
 Sets a table field.
 
void set (std::tuple< Ts... > &&t) const
 Sets multiple table fields.
 

Private Member Functions

int begin_op (void) const
 
void end_op (int i) const
 

Private Attributes

state_view m_state = {}
 

Additional Inherited Members

- Protected Member Functions inherited from nngn::lua::detail::table_base< global_table >
T get_common (auto &&k, T &&def=T{}) const
 
void set_common (auto &&k, auto &&v) const
 

Detailed Description

Table interface to the global environment.

Constructor & Destructor Documentation

◆ global_table() [1/4]

nngn::lua::global_table::global_table ( )
default

◆ global_table() [2/4]

nngn::lua::global_table::global_table ( const global_table & )
default

◆ global_table() [3/4]

nngn::lua::global_table::global_table ( global_table && )
defaultnoexcept

◆ global_table() [4/4]

nngn::lua::global_table::global_table ( state_view lua)
inlineexplicit

◆ ~global_table()

nngn::lua::global_table::~global_table ( void )
default

Member Function Documentation

◆ begin_op()

int nngn::lua::global_table::begin_op ( void ) const
inlineprivate
Here is the call graph for this function:

◆ end_op()

void nngn::lua::global_table::end_op ( int i) const
inlineprivate
Here is the call graph for this function:

◆ operator=() [1/2]

global_table & nngn::lua::global_table::operator= ( const global_table & )
default

◆ operator=() [2/2]

global_table & nngn::lua::global_table::operator= ( global_table && )
defaultnoexcept

◆ push()

int nngn::lua::global_table::push ( void ) const
inline
Here is the call graph for this function:
Here is the caller graph for this function:

◆ state()

state_view nngn::lua::global_table::state ( void ) const
inline
Here is the caller graph for this function:

Member Data Documentation

◆ m_state

state_view nngn::lua::global_table::m_state = {}
private

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