Library globals

Class globals . props . Node

View source

Node class definition.  The class methods simply wrap the
low level extension functions which work on a "ghost" handle to a
SGPropertyNode object stored in the _g field.

Not all of the features of SGPropertyNode are supported.  There is
no support for ties, obviously, as that wouldn't make much sense
from a Nasal context.  The various get/set methods work only on the
local node, there is no equivalent of the "relative path" variants
available in C++; just use node.getNode(path).whatever() instead.

Functions

addChild

addChildren

adjustValue

adjustValue works like setDoubleValue but adds the argument to the current value of the node

alias

clearValue

decrement

sub n from int property, do nothing, if prop type is not int n will be integer and defaults to 1

equals

getAliasTarget

getAttribute

getBoolValue

getChild

getChildren

getDoubleValue

getIndex

getIntValue

getName

getNode

getParent

getPath

getType

getValue

increment

add n to int property, do nothing, if prop type is not int n will be integer and defaults to 1

isInt

isNumeric

isValidPropName

checks if a string can be used as a prop name returns 0 (invalid) or 1 (valid) as string operations are expensive, use this only when necessary, especially do not use in update loops

makeValidPropName

replaces any invalid char by "_" as string operations are expensive, use this only when necessary, especially do not use in update loops

remove

removeAllChildren

removeChild

removeChildren

resolveAlias

follow alias links to "real" node (e.g. where the data is stored) optional argument: property node or prop path to resolve if no argument is given, operate on current obj ("me")

setAttribute

setBoolValue

setChildren

setDoubleValue

setIntValue

setValue

setValues

toggleBoolValue

unalias