code: private void readLeafTasks(Task parent, Integer id)
     {
        Integer currentID = id;
        Table table = getTable("A1TAB");
        while (currentID.intValue() != 0)
        {
           if (m_projectFile.getTaskByUniqueID(currentID) == null)
           {
              readTask(parent, currentID);
           }
           currentID = table.find(currentID).getInteger("NEXT_TASK_ID");
        }
     }
docs: Read the leaf tasks for an individual WBS node.
  
  @param parent parent task
  @param id first task ID