code: private void readTasks(Project project)
     {
        Project.Tasks tasks = project.getTasks();
        if (tasks != null)
        {
           int tasksWithoutIDCount = 0;
  
           for (Project.Tasks.Task task : tasks.getTask())
           {
              Task mpxjTask = readTask(task);
              if (mpxjTask.getID() == null)
              {
                 ++tasksWithoutIDCount;
              }
           }
  
           for (Project.Tasks.Task task : tasks.getTask())
           {
              readPredecessors(task);
           }
  
           //
           // MS Project will happily read tasks from an MSPDI file without IDs,
           // it will just generate ID values based on the task order in the file.
           // If we find that there are no ID values present, we'll do the same.
           //
           if (tasksWithoutIDCount == tasks.getTask().size())
           {
              m_projectFile.getTasks().renumberIDs();
           }
        }
  
        m_projectFile.updateStructure();
     }
docs: This method extracts task data from an MSPDI file.
  
  @param project Root node of the MSPDI file