aot_top_get_val Interface

public interface aot_top_get_val

Get the value on top of the Lua API stack

This is the most basic operation to retrieve a value. It is also most flexible in the sense, that it does not matter how the value actually gets on top of the stack by previous Lua operations.

The interface looks like this: call aot_top_get_val(val, errCode, L, default). See for example aot_top_get_real for a more detailed description of the parameters.

aot_top_get_val can not be in the same generic interface as the other aot_get_val routines, as it results in ambiguities of the interfaces.

Calls

interface~~aot_top_get_val~~CallsGraph interface~aot_top_get_val aot_top_get_val proc~aot_top_get_long aot_top_get_long interface~aot_top_get_val->proc~aot_top_get_long proc~aot_top_get_logical aot_top_get_logical interface~aot_top_get_val->proc~aot_top_get_logical proc~aot_top_get_userdata aot_top_get_userdata interface~aot_top_get_val->proc~aot_top_get_userdata proc~aot_top_get_double aot_top_get_double interface~aot_top_get_val->proc~aot_top_get_double proc~aot_top_get_real aot_top_get_real interface~aot_top_get_val->proc~aot_top_get_real proc~aot_top_get_integer aot_top_get_integer interface~aot_top_get_val->proc~aot_top_get_integer proc~aot_top_get_string aot_top_get_string interface~aot_top_get_val->proc~aot_top_get_string proc~flu_pop flu_pop proc~aot_top_get_long->proc~flu_pop proc~flu_todouble flu_todouble proc~aot_top_get_long->proc~flu_todouble flu_isnoneornil flu_isnoneornil proc~aot_top_get_long->flu_isnoneornil proc~flu_isnumber flu_isnumber proc~aot_top_get_long->proc~flu_isnumber proc~aot_top_get_logical->proc~flu_pop flu_toboolean flu_toboolean proc~aot_top_get_logical->flu_toboolean flu_isboolean flu_isboolean proc~aot_top_get_logical->flu_isboolean proc~aot_top_get_logical->flu_isnoneornil proc~aot_top_get_userdata->proc~flu_pop proc~flu_islightuserdata flu_islightuserdata proc~aot_top_get_userdata->proc~flu_islightuserdata proc~flu_touserdata flu_touserdata proc~aot_top_get_userdata->proc~flu_touserdata proc~aot_top_get_userdata->flu_isnoneornil proc~aot_top_get_double->proc~flu_pop proc~aot_top_get_double->proc~flu_todouble proc~aot_top_get_double->flu_isnoneornil proc~aot_top_get_double->proc~flu_isnumber proc~flu_tonumber flu_tonumber proc~aot_top_get_real->proc~flu_tonumber proc~aot_top_get_real->proc~flu_pop proc~aot_top_get_real->flu_isnoneornil proc~aot_top_get_real->proc~flu_isnumber proc~aot_top_get_integer->proc~flu_pop proc~aot_top_get_integer->proc~flu_todouble proc~aot_top_get_integer->flu_isnoneornil proc~aot_top_get_integer->proc~flu_isnumber proc~aot_top_get_string->proc~flu_pop proc~aot_top_get_string->flu_isnoneornil proc~flu_tolstring flu_tolstring proc~aot_top_get_string->proc~flu_tolstring flu_isstring flu_isstring proc~aot_top_get_string->flu_isstring interface~lua_tonumberx lua_tonumberx proc~flu_tonumber->interface~lua_tonumberx interface~lua_settop lua_settop proc~flu_pop->interface~lua_settop proc~flu_todouble->interface~lua_tonumberx interface~lua_type lua_type proc~flu_islightuserdata->interface~lua_type interface~lua_touserdata lua_touserdata proc~flu_touserdata->interface~lua_touserdata interface~lua_tolstring lua_tolstring proc~flu_tolstring->interface~lua_tolstring lua_isnumber lua_isnumber proc~flu_isnumber->lua_isnumber

Contents


Module Procedures

private subroutine aot_top_get_real(val, ErrCode, L, default)

Interpret topmost entry on Lua stack as a single precision real.

Arguments

TypeIntentOptionalAttributesName
real(kind=single_k), intent(out) :: val

Value of the Variable in the script

integer, intent(out) :: ErrCode

Error code to indicate what kind of problem might have occured.

type(flu_State) :: L

Handle to the Lua script

real(kind=single_k), intent(in), optional :: default

Some default value, that should be used, if the variable is not set in the Lua script.

private subroutine aot_top_get_double(val, ErrCode, L, default)

Interpret topmost entry on Lua stack as a double precision real.

Arguments

TypeIntentOptionalAttributesName
real(kind=double_k), intent(out) :: val

Value of the Variable in the script

integer, intent(out) :: ErrCode

Error code to indicate what kind of problem might have occured.

type(flu_State) :: L

Handle to the Lua script

real(kind=double_k), intent(in), optional :: default

Some default value, that should be used, if the variable is not set in the Lua script.

private subroutine aot_top_get_integer(val, ErrCode, L, default)

Interpret topmost entry on Lua stack as a default integer.

Arguments

TypeIntentOptionalAttributesName
integer(kind=int_k), intent(out) :: val

Value of the Variable in the script

integer, intent(out) :: ErrCode

Error code to indicate what kind of problem might have occured.

type(flu_State) :: L

Handle to the Lua script

integer(kind=int_k), intent(in), optional :: default

Some default value, that should be used, if the variable is not set in the Lua script.

private subroutine aot_top_get_long(val, ErrCode, L, default)

Interpret topmost entry on Lua stack as a single precision real.

Arguments

TypeIntentOptionalAttributesName
integer(kind=long_k), intent(out) :: val

Value of the Variable in the script

integer, intent(out) :: ErrCode

Error code to indicate what kind of problem might have occured.

type(flu_State) :: L

Handle to the Lua script

integer(kind=long_k), intent(in), optional :: default

Some default value, that should be used, if the variable is not set in the Lua script.

private subroutine aot_top_get_string(val, ErrCode, L, default)

Interpret topmost entry on Lua stack as a single precision real.

Arguments

TypeIntentOptionalAttributesName
character(len=*) :: val

Value of the Variable in the script

integer, intent(out) :: ErrCode

Error code to indicate what kind of problem might have occured.

type(flu_State) :: L

Handle to the Lua script

character(len=*), intent(in), optional :: default

Some default value, that should be used, if the variable is not set in the Lua script.

private subroutine aot_top_get_logical(val, ErrCode, L, default)

Interpret topmost entry on Lua stack as a single precision real.

Arguments

TypeIntentOptionalAttributesName
logical, intent(out) :: val

Value of the Variable in the script

integer, intent(out) :: ErrCode

Error code to indicate what kind of problem might have occured.

type(flu_State) :: L

Handle to the Lua script

logical, intent(in), optional :: default

Some default value, that should be used, if the variable is not set in the Lua script.

private subroutine aot_top_get_userdata(val, ErrCode, L, default)

Interpret topmost entry on Lua stack as userdata.

Arguments

TypeIntentOptionalAttributesName
type(c_ptr), intent(out) :: val

Value of the Variable in the script

integer, intent(out) :: ErrCode

Error code to indicate what kind of problem might have occured.

type(flu_State) :: L

Handle to the Lua script

type(c_ptr), intent(in), optional :: default

Some default value, that should be used, if the variable is not set in the Lua script.