Websites Navigation:
Airbit
|
Shop
|
m-shell.net
Languages:
EN
|
DE
Home
Downloads
Products
Make SIS
Documentation
Forum
Blog
Contact
Index
Module abprops
Class abprops.Properties
A list of properties, with functions to read the from and write them to a text file.
Constructor
function init(name=null)
Initialize this list, and optionally load it from a text file.
Parameters:
name
– the file name, null to load no file.
Fields
entries
The entries (associative array).
Functions
get
(key)
Get a property as string.
getNum
(key)
Get a numeric property.
read
(name, ces=...)
Add properties from a text file.
set
(key, value)
Set a property.
write
(name, ces=...)
Write properties to a text file.
function read(name, ces=io.utf8)
Add properties from a text file.
Parameters:
name
– the file name.
ces
– the character encoding to use.
function get(key)
Get a property as string.
Parameters:
key
– the property key.
Returns:
the property value, or null if there is no such property.
function getNum(key)
Get a numeric property.
Parameters:
key
– the property key.
Returns:
the property value, or -1 if there is no such number property.
function set(key, value)
Set a property.
Parameters:
key
– the property key.
value
– the property value. If not a string, it is converted to a string.
function write(name, ces=io.utf8)
Write properties to a text file.
Parameters:
name
– the file name.
ces
– the character encoding to use.
mShell Home
>
Documentation
> mdoc