Defines a number column with the given name. This and all of the other Page.Type
functions are passed to New()
to define the structure of each row. When tables are saved to the Page, the column name defines the key to search for a number value. In addition, tables obtained from the Page will have a key identified by the column name filled with a number value.
Definition
Column Number (String name)
Arguments
String name
The name of the column.
Returns
Returns a Column object which is passed in an array to New()
.
Example
local myPage = Page.New("myPage", 32, { Page.Type.String ("Name", 64), Page.Type.Number "Score", Page.Type.Bool "IsBanned", }) myPage:Set(0, { Name = "Joe", Score = 0, IsBanned = true, }) local row = myPage:Get(0) print(row.Score)