NBS_DEFINE_PRIMITIVE

Define a new entry for a primitive item within another structured item and return a static identifier to the new item

Description:

Check that we are currently in the middle of defining a noticeboard.
Check that the environment static ID is not NIL and does not pertain to a primitive item.
Allocate space to describe the new item and fill in fields appropriate to a primitive item such that items at this level are in alphabetical order. (If an item of this name already exists, create a new item but position it before the existing item).
Return the address of the item descriptor to the caller for use in subsequent calls.

Invocation

(Int) = NBS_DEFINE_PRIMITIVE (ENVSID,NAME,TYPE,MAXDIMS,MAXBYTES,SID,
STATUS)

Arguments

ENVSID = INTEGER (Given)
Static identifier of the item in the noticeboard which is the parent of the item to be created.
NAME = CHARACTER∗(∗) (Given)
Name of the new item.
TYPE = CHARACTER∗(∗) (Given)
Type of the new item.
MAXDIMS = INTEGER (Given)
Maximum number of dimensions possessed by this item.
MAXBYTES = INTEGER (Given)
Maximum number of bytes in this item’s value
SID = INTEGER (Returned)
Static identifier of the new structured item. This should be used in subsequent calls to the NBS_DEFINE_∗ routines (only NBS_DEFINE_SHAPE is permitted though).
STATUS = INTEGER (Given and returned)
The global status. Possible return values are,
NBS__NOTDEFINING Not currently defining a noticeboard

NBS__NILSID NIL static ID

NBS__PRIMITIVE Prospective parent is primitive

NBS__NOMOREROOM Storage area is full up