Category
Metatables
Metatables, metafields, and namecall methods.Category guide
Overview
Use this overview to understand the category before opening a specific function.- See what this group of functions is meant to solve.
- Compare function names and descriptions in one table.
- Open a function for syntax, arguments, returns, and examples.
Metatables
Available functions
| Function | Description |
|---|---|
getmetafield | Returns a raw metafield value from the target metatable. |
getnamecallmethod | Returns the current namecall method string when one is available, otherwise nil. |
getrawmetatable | Returns the metatable currently attached to a target value, or nil when none is present. |
hasmetafield | Returns whether the target value has a non-nil raw metafield with the requested name. |
hasmetatable | Returns whether the target value has a metatable. |
isreadonly | Returns whether a table is readonly. |
makereadonly | Marks a table as readonly and returns no values. |
makewriteable | Marks a table as writable and returns no values. |
setnamecallmethod | Replaces the current namecall method string when a current namecall method exists. |
setrawmetatable | Sets the metatable for a target value and returns the original target. |
setreadonly | Sets whether a table is readonly and returns no values. |