Package hu.u_szeged.nbo.res_alloc.model.container

Examples of hu.u_szeged.nbo.res_alloc.model.container.ResourceDemandContainer


 
  /** Call loadTasks method before this */
  private void loadTaskResDemand(String filename)
  throws FileNotFoundException, IOException {
    try {
      ResourceDemandContainer rdc = new ResourceDemandContainer(model);
      StringTokenizer tokenizer = this.openFile(filename);
     
      //ignore header fields
      tokenizer.nextToken();
      tokenizer.nextToken();
     
      while (tokenizer.hasMoreTokens()) {
        ResourceDemand rd = new ResourceDemand();
        int id = Integer.parseInt(tokenizer.nextToken());
        rd.setId(id);
        int task_id = Integer.parseInt(tokenizer.nextToken());
        rd.setTask(model.getTaskContainer().getTaskById(task_id));
       
        rdc.putResourceDemand(id, rd);
       
        model.getTaskContainer().getTaskById(task_id).putResourceDemand(rd);
      }
      model.setResourceDemandContainer(rdc);
    }
View Full Code Here

TOP

Related Classes of hu.u_szeged.nbo.res_alloc.model.container.ResourceDemandContainer

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.