newspeoplefor developersdocumentationdownloads

nRoot Script Interface

nroot:

Super Class:

Subclasses:

C++ Class:

Info

nroot is the superclass of all higher level NOH-dependent Nebula classes and defines this basic behavior and properties for all nroot derived classes:
  • linkage into hierarchical name space of objects
  • runtime type information (through nobject)
  • object persistency
  • language independent scripting interface

Commands:


save

Command Input:
v
Command Output:
b (Success)
Command Description:
Save the object under its current name into a filesystem file. The filename will be 'name_of_object.n'. Such a persistent object file must be read back with the nsh 'get' command.

getparent

Command Input:
v
Command Output:
o (ObjectHandle)
Command Description:
Return the full pathname of the parent object. If the object doesn't have a parent object (this is only valid for the root object '/'), 'null' will be returned.

gethead

Command Input:
v
Command Output:
o (ObjectHandle)
Command Description:
Return full pathname of first child object, or 'null' if no child objects exist.

gettail

Command Input:
v
Command Output:
o (ObjectHandle)
Command Description:
Return full pathname of last child object, or 'null' if no child objects exist.

getsucc

Command Input:
v
Command Output:
o (ObjectHandle)
Command Description:
Return full pathname of next object in the same hierarchy level, zero if no next object exists.

getpred

Command Input:
v
Command Output:
o (ObjectHandle)
Command Description:
Return full pathname of previous object in the same hierarchy level, zero if no previous object exists.

getchildren

Command Input:
v
Command Output:
l (ListArg)
Command Description:
Return a list of all children.

setname

Command Input:
s (Name)
Command Output:
v
Command Description:
Give the object a new name ('Name' may not contain any path components!).

getname

Command Input:
v
Command Output:
s (Name)
Command Description:
Return the object's name without path.

getfullname

Command Input:
v
Command Output:
s (Name)
Command Description:
Return the full pathname of the object.

getrelpath

Command Input:
o (OtherObject)
Command Output:
s (Path)
Command Description:
Return the shortest relative path leading from this object to the given object.

find

Command Input:
s (Name)
Command Output:
o (PathName)
Command Description:
Find a child object with name 'Name'. Return full path of child if found, or 'null' if not found.

sort

Command Input:
v
Command Output:
v
Command Description:
Sort all child objects alphabetically.

gettreesize

Command Input:
v
Command Output:
i (TreeInstanceSize)
Command Description:
This is the recursive version of getinstancesize.

Copyright © 1999-2005 by the contributing authors. Ideas, requests, problems: Send feedback.