Difference between revisions of "(global)"
Line 1: | Line 1: | ||
__NOTOC__ | __NOTOC__ | ||
+ | <!-- GIDEROSOBJ:(global) --> | ||
'''<translate>Supported platforms</translate>:''' [[File:Platform android.png]][[File:Platform ios.png]][[File:Platform mac.png]][[File:Platform pc.png]]<br/> | '''<translate>Supported platforms</translate>:''' [[File:Platform android.png]][[File:Platform ios.png]][[File:Platform mac.png]][[File:Platform pc.png]]<br/> | ||
'''<translate>Available since</translate>:''' Gideros 2011.6<br/> | '''<translate>Available since</translate>:''' Gideros 2011.6<br/> | ||
Line 7: | Line 8: | ||
| style="width: 50%; vertical-align:top;"| | | style="width: 50%; vertical-align:top;"| | ||
=== <translate>Methods</translate> === | === <translate>Methods</translate> === | ||
− | [[Special:MyLanguage/assert|assert]] ''<translate>error if v nil or false, otherwise returns v</translate>''<br/> | + | [[Special:MyLanguage/assert|assert]] ''<translate>error if v nil or false, otherwise returns v</translate>''<br/><!-- GIDEROSMTD:assert --> |
− | [[Special:MyLanguage/collectgarbage|collectgarbage]] ''<translate>opts: stop, restart, collect, count, step, setpause, setstepmul</translate>''<br/> | + | [[Special:MyLanguage/collectgarbage|collectgarbage]] ''<translate>opts: stop, restart, collect, count, step, setpause, setstepmul</translate>''<br/><!-- GIDEROSMTD:collectgarbage --> |
− | [[Special:MyLanguage/dofile|dofile]] ''<translate>executes as Lua chunk, default stdin, returns value</translate>''<br/> | + | [[Special:MyLanguage/dofile|dofile]] ''<translate>executes as Lua chunk, default stdin, returns value</translate>''<br/><!-- GIDEROSMTD:dofile --> |
− | [[Special:MyLanguage/error|error]] ''<translate>terminates protected func, never returns</translate>''<br/> | + | [[Special:MyLanguage/error|error]] ''<translate>terminates protected func, never returns</translate>''<br/><!-- GIDEROSMTD:error --> |
− | [[Special:MyLanguage/getfenv|getfenv]] ''<translate>gets env, f can be a function or number(stack level)</translate>''<br/> | + | [[Special:MyLanguage/getfenv|getfenv]] ''<translate>gets env, f can be a function or number(stack level)</translate>''<br/><!-- GIDEROSMTD:getfenv --> |
− | [[Special:MyLanguage/getmetatable|getmetatable]] ''<translate>returns metatable of given object, otherwise nil</translate>''<br/> | + | [[Special:MyLanguage/getmetatable|getmetatable]] ''<translate>returns metatable of given object, otherwise nil</translate>''<br/><!-- GIDEROSMTD:getmetatable --> |
− | [[Special:MyLanguage/ipairs|ipairs]] ''<translate>returns an iterator function, table t and 0</translate>''<br/> | + | [[Special:MyLanguage/ipairs|ipairs]] ''<translate>returns an iterator function, table t and 0</translate>''<br/><!-- GIDEROSMTD:ipairs --> |
− | [[Special:MyLanguage/loadfile|loadfile]] ''<translate>loads chunk without execution, returns chunk as function, else nil plus error</translate>''<br/> | + | [[Special:MyLanguage/loadfile|loadfile]] ''<translate>loads chunk without execution, returns chunk as function, else nil plus error</translate>''<br/><!-- GIDEROSMTD:loadfile --> |
− | [[Special:MyLanguage/loadstring|loadstring]] ''<translate>loads string as chunk, returns chunk as function, else nil plus error</translate>''<br/> | + | [[Special:MyLanguage/loadstring|loadstring]] ''<translate>loads string as chunk, returns chunk as function, else nil plus error</translate>''<br/><!-- GIDEROSMTD:loadstring --> |
− | [[Special:MyLanguage/next|next]] ''<translate>returns next index,value pair, if index=nil(default-, returns first index</translate>''<br/> | + | [[Special:MyLanguage/next|next]] ''<translate>returns next index,value pair, if index=nil(default-, returns first index</translate>''<br/><!-- GIDEROSMTD:next --> |
− | [[Special:MyLanguage/pairs|pairs]] ''<translate>returns the next function and table t plus a nil, iterates over all key-value pairs</translate>''<br/> | + | [[Special:MyLanguage/pairs|pairs]] ''<translate>returns the next function and table t plus a nil, iterates over all key-value pairs</translate>''<br/><!-- GIDEROSMTD:pairs --> |
− | [[Special:MyLanguage/pcall|pcall]] ''<translate>protected mode call, catches errors, returns status code first</translate>''<br/> | + | [[Special:MyLanguage/pcall|pcall]] ''<translate>protected mode call, catches errors, returns status code first</translate>''<br/><!-- GIDEROSMTD:pcall --> |
− | [[Special:MyLanguage/print|print]] ''<translate>prints values to stdout using tostring</translate>''<br/> | + | [[Special:MyLanguage/print|print]] ''<translate>prints values to stdout using tostring</translate>''<br/><!-- GIDEROSMTD:print --> |
− | [[Special:MyLanguage/rawequal|rawequal]] ''<translate>non-metamethod v1==v2, returns boolean</translate>''<br/> | + | [[Special:MyLanguage/rawequal|rawequal]] ''<translate>non-metamethod v1==v2, returns boolean</translate>''<br/><!-- GIDEROSMTD:rawequal --> |
− | [[Special:MyLanguage/rawget|rawget]] ''<translate>non-metamethod get value of table[index], index != nil</translate>''<br/> | + | [[Special:MyLanguage/rawget|rawget]] ''<translate>non-metamethod get value of table[index], index != nil</translate>''<br/><!-- GIDEROSMTD:rawget --> |
− | [[Special:MyLanguage/rawset|rawset]] ''<translate>non-metamethod set value of table[index], index != nil</translate>''<br/> | + | [[Special:MyLanguage/rawset|rawset]] ''<translate>non-metamethod set value of table[index], index != nil</translate>''<br/><!-- GIDEROSMTD:rawset --> |
− | [[Special:MyLanguage/require|require]] ''<translate>loads package, updates _LOADED, returns boolean</translate>''<br/> | + | [[Special:MyLanguage/require|require]] ''<translate>loads package, updates _LOADED, returns boolean</translate>''<br/><!-- GIDEROSMTD:require --> |
− | [[Special:MyLanguage/setfenv|setfenv]] ''<translate>sets env, f can be a function or number(stack level, default=1-, 0=global env</translate>''<br/> | + | [[Special:MyLanguage/setfenv|setfenv]] ''<translate>sets env, f can be a function or number(stack level, default=1-, 0=global env</translate>''<br/><!-- GIDEROSMTD:setfenv --> |
− | [[Special:MyLanguage/setmetatable|setmetatable]] ''<translate>sets metatable, nil to remove metatable</translate>''<br/> | + | [[Special:MyLanguage/setmetatable|setmetatable]] ''<translate>sets metatable, nil to remove metatable</translate>''<br/><!-- GIDEROSMTD:setmetatable --> |
− | [[Special:MyLanguage/tonumber|tonumber]] ''<translate>convert to number, returns number, nil if non-convertible, 2<=base<=36</translate>''<br/> | + | [[Special:MyLanguage/tonumber|tonumber]] ''<translate>convert to number, returns number, nil if non-convertible, 2<=base<=36</translate>''<br/><!-- GIDEROSMTD:tonumber --> |
− | [[Special:MyLanguage/tostring|tostring]] ''<translate>convert to string, returns string</translate>''<br/> | + | [[Special:MyLanguage/tostring|tostring]] ''<translate>convert to string, returns string</translate>''<br/><!-- GIDEROSMTD:tostring --> |
− | [[Special:MyLanguage/type|type]] ''<translate>returns type of v as a string</translate>''<br/> | + | [[Special:MyLanguage/type|type]] ''<translate>returns type of v as a string</translate>''<br/><!-- GIDEROSMTD:type --> |
− | [[Special:MyLanguage/unpack|unpack]] ''<translate>returns all elements from list</translate>''<br/> | + | [[Special:MyLanguage/unpack|unpack]] ''<translate>returns all elements from list</translate>''<br/><!-- GIDEROSMTD:unpack --> |
− | [[Special:MyLanguage/xpcall|xpcall]] ''<translate>pcall function f with new error handler err</translate>''<br/> | + | [[Special:MyLanguage/xpcall|xpcall]] ''<translate>pcall function f with new error handler err</translate>''<br/><!-- GIDEROSMTD:xpcall --> |
| style="width: 50%; vertical-align:top;"| | | style="width: 50%; vertical-align:top;"| | ||
=== <translate>Events</translate> === | === <translate>Events</translate> === | ||
=== <translate>Constants</translate> === | === <translate>Constants</translate> === | ||
− | [[Special:MyLanguage/_G|_G]]<br/> | + | [[Special:MyLanguage/_G|_G]]<br/><!-- GIDEROSCST:_G --> |
− | [[Special:MyLanguage/_VERSION|_VERSION]]<br/> | + | [[Special:MyLanguage/_VERSION|_VERSION]]<br/><!-- GIDEROSCST:_VERSION --> |
|} | |} |
Revision as of 14:53, 31 August 2018
Supported platforms:
Available since: Gideros 2011.6
Description
Global scope of Lua environment
Methodsassert error if v nil or false, otherwise returns v |
EventsConstants |