public WorkloadFileReader(final String fileName,final int rating) throws FileNotFoundException {
  if (fileName == null || fileName.length() == 0) {
    throw new IllegalArgumentException("Invalid trace file name.");
  }
 else   if (rating <= 0) {
    throw new IllegalArgumentException("Resource PE rating must be > 0.");
  }
  file=new File(fileName);
  if (!file.exists()) {
    throw new FileNotFoundException("Workload trace " + fileName + " does not exist");
  }
  this.rating=rating;
}

public WorkloadFileReader ( final String fileName , final int rating ) throws FileNotFoundException { if ( fileName == null || fileName . length ( ) == 0 ) { throw new IllegalArgumentException ( "Invalid trace file name." ) ; } else if ( rating <= 0 ) { throw new IllegalArgumentException ( "Resource PE rating must be > 0." ) ; } file = new File ( fileName ) ; if ( ! file . exists ( ) ) { throw new FileNotFoundException ( "Workload trace " + fileName + " does not exist" ) ; } this . rating = rating ; }
create a new workloadfilereader object .
