Leaves and Nodes Insert Verification

InsertChildLeaf, InsertSibNode, InsertChildNode, and so on, can return False or a Null object reference, depending upon the type of error encountered. You may want to declare references to new leaves or nodes as type ANY until after you verify they were actually created. You can do this by using the None or All PeopleCode functions to determine whether a valid Leaf or Node Object was created. If a Leaf or Node object was created ALL()returns True and None() returns False.

&NewLeaf = &RootNode.InsertChildLeaf("8000", "8999"); 
If NONE(&NewLeaf) Then 
   /* Leaf not inserted, do error processing */ 
   &Messages = &Session.PSMessages; 
   If &Messages.WarningPending Then 
      /* do error processing */ 
   End-if; 
End-if;