java.lang.Object
edu.isi.pegasus.planner.selector.site.heft.Site

public class Site extends Object
A data class that models a site as a collection of processors. The number of processors can only be specified in the constructor.
Version:
$Revision$
Author:
Karan Vahi
  • Field Details

    • mNumProcessors

      private int mNumProcessors
      The number of processors making up a site.
    • mProcessors

      private List mProcessors
      A list of processors making up the site.
    • mCurrentProcessorIndex

      private int mCurrentProcessorIndex
      The index to the processor that is to be used for scheduling a job.
    • mName

      private String mName
      The logical name assigned to the site.
  • Constructor Details

    • Site

      public Site(String name)
      The default constructor.
      Parameters:
      name - the name to be assigned to the site.
    • Site

      public Site(String name, int num)
      The overloaded constructor.
      Parameters:
      name - the name to be assigned to the site.
      num - the number of processors.
  • Method Details

    • getAvailableTime

      public long getAvailableTime(long start)
      Returns the earliest time the site is available for scheduling a job. It is non insertion based scheduling policy.
      Parameters:
      start - the time at which to start the search.
      Returns:
      long
    • scheduleJob

      public void scheduleJob(long start, long end)
      Schedules a job to the site.
      Parameters:
      start - the start time of the job.
      end - the end time for the job
    • getName

      public String getName()
      Returns the name of the site.
      Returns:
      name of the site.
    • getAvailableProcessors

      public int getAvailableProcessors()
      Returns the number of available processors.
      Returns:
      number of available processors.