NAME
CL_LuaReference - Lua reference
DESCRIPTION
If the user needs to store references to LuaObject, this reference must be explicitly created, creating objects of this class.
Inherited from public CL_LuaObject
CLASS MEMBERS
- CL_LuaReference(
-
void)
- CL_LuaReference(
-
const CL_LuaObject& obj, int lock=0)
- void ref(
-
const CL_LuaObject& obj, int lock=0)
- void unref(
-
void)
MEMBERS WITH DESCRIPTIONS
- CL_LuaReference(
-
void)
Description:
Create a reference to a nil object (default)
- CL_LuaReference(
-
const CL_LuaObject& obj, int lock=0)
Parameters: lock - to lock or not to lock, that is the question
Description:
Create a reference to the given Lua object An optinal parameter specifies if the reference is not to be garbage collected by Lua. The default, {lock=0}, means the reference becomes invalid if Lua collects the referenced object.
- void ref(
-
const CL_LuaObject& obj, int lock=0)
Description:
Replace the reference This method allows the user to replace the referenced object; it is useful when the object is created with the default constructor. _Note_: if there is already a reference to a non-'nil' object, this reference, if not used by other LuaReference objets, should be eliminated (using the 'unref' method) before calling this method.
- void unref(
-
void)
Description:
Unreference an object
SEE ALSO
All ClanLib API classes can be found in clanlib (3).
AUTHORS
Originally written by Magnus Norddahl <[email protected]> and Martin Starch <[email protected]>. ClanLib is now developed by the ClanLib Development team as an Open Source project.
The ClanLib man pages was created using the Perceps documentation system (another excellent piece of Open Source software, available at http://somewhere.in.the.world.org).
See clanlib (3) to find out how to get a full list of contributors and details on how to submit bug reports, comments etc.