public interface MetatableProvider
In Lua, only tables and (full) userdata carry their own metatables; for all other types of values T, all values of type T share a metatable. This interface provides uniform access to metatables of all types.
Modifier and Type | Method and Description |
---|---|
Table |
getBooleanMetatable()
Returns the metatable for
boolean values, or null if this provider does
not assign a metatable to the boolean type. |
Table |
getFunctionMetatable()
Returns the metatable for
function values, or null if this provider does
not assign a metatable to the function type. |
Table |
getLightUserdataMetatable()
Returns the metatable for light userdata, or
null if this provider does
not assign a metatable to light userdata.. |
Table |
getMetatable(Object instance)
Returns the metatable for the object
instance , or null if this
metatable provider does not assign any metatable to instance . |
Table |
getNilMetatable()
Returns the metatable for nil (the
nil type), or null if this
provider does not assign a metatable to the nil type. |
Table |
getNumberMetatable()
Returns the metatable for
number values, or null if this provider does
not assign a metatable to the number type. |
Table |
getStringMetatable()
Returns the metatable for
string values, or null if this provider does
not assign a metatable to the string type. |
Table |
getThreadMetatable()
Returns the metatable for
thread values, or null if this provider does
not assign a metatable to the thread type. |
Table getNilMetatable()
nil
type), or null
if this
provider does not assign a metatable to the nil
type.nil
typeTable getBooleanMetatable()
boolean
values, or null
if this provider does
not assign a metatable to the boolean
type.boolean
typeTable getNumberMetatable()
number
values, or null
if this provider does
not assign a metatable to the number
type.number
typeTable getStringMetatable()
string
values, or null
if this provider does
not assign a metatable to the string
type.string
typeTable getFunctionMetatable()
function
values, or null
if this provider does
not assign a metatable to the function
type.function
typeTable getThreadMetatable()
thread
values, or null
if this provider does
not assign a metatable to the thread
type.thread
typeTable getLightUserdataMetatable()
null
if this provider does
not assign a metatable to light userdata..Table getMetatable(Object instance)
instance
, or null
if this
metatable provider does not assign any metatable to instance
.instance
- the object to obtain a metatable for, may be null
instance
, or null
if there is no metatable
assigned to instance
in this providerCopyright © 2016. All rights reserved.