edu.isi.pegasus.planner.provisioner
Class OccupationDiagram

java.lang.Object
  extended by edu.isi.pegasus.planner.provisioner.OccupationDiagram

public class OccupationDiagram
extends Object

This class keeps structure of an Occupation Diagram and conduct BTS algorithm

Author:
Eunkyu Byun

Nested Class Summary
private  class OccupationDiagram.NodeComp
          Comparator which compare the schedulable duration of two nodes
 
Field Summary
(package private)  int max
           
(package private)  int maxIndex
           
(package private)  TreeSet nodes
           
(package private)  long RFT
           
(package private)  LinkedList[] timeMap
           
 
Constructor Summary
OccupationDiagram(long rft)
          Constructor
 
Method Summary
 void add(Node node)
          Add tasks into the occupation diagram.
 int balance(int goal, boolean print)
          Run Task redistribution phase of BTS algorithm
private  void printNodes()
           
 int stack(boolean print)
          Run Task placement phase of BTS algorithm
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

nodes

TreeSet nodes

RFT

long RFT

timeMap

LinkedList[] timeMap

max

int max

maxIndex

int maxIndex
Constructor Detail

OccupationDiagram

public OccupationDiagram(long rft)
Constructor

Parameters:
rft - Requested finish time(deadline) of algorithm.
Method Detail

add

public void add(Node node)
Add tasks into the occupation diagram. But task placement is not conducted yet

Parameters:
node - Node to be added

printNodes

private void printNodes()

stack

public int stack(boolean print)
Run Task placement phase of BTS algorithm

Parameters:
print - if true print debug message to stdout
Returns:
maxinum height of Occupation diagram when Task placement is done

balance

public int balance(int goal,
                   boolean print)
Run Task redistribution phase of BTS algorithm

Parameters:
goal - Redistribution loop is stop if maximum height of OD reach this goal value.
print - if true print debug message to stdout
Returns:
maxinum height of Occupation diagram when Task redistribution is done


Copyright © 2011 The University of Southern California. All Rights Reserved.