edu.isi.pegasus.planner.partitioner

## Class MultipleLook

- java.lang.Object
- - edu.isi.pegasus.planner.partitioner.DAXWriter
  - - edu.isi.pegasus.planner.partitioner.MultipleLook

    public class MultipleLook
    extends DAXWriter

This class ends up writing a partitioned dax, that corresponds to one partition as defined by the Partitioner. Whenever it is called to write out a dax corresponding to a partition it looks up the dax i.e parses the dax and gets the information about the jobs making up the partition.

Version:
  $Revision$
Author:
  Karan Vahi

### Nested Class Summary

Nested Classes
`private class` `MultipleLook.MyCallBackHandler` The internal callback handler for the DAXParser in Euryale.

### Field Summary

Fields
`private int` `mCurrentNum` The number of jobs about which the callback interface has knowledge.
`private int` `mIndex` The index of the partition that is being written out.
`private java.util.Set` `mNodeSet` The set of job id's in the partition.
`private int` `mNumOfJobs` The number of jobs that are in the partition.
`private org.griphyn.vdl.dax.ADAG` `mPartADAG` The ADAG object containing the partitioned dax.
`private java.util.Map` `mRelationsMap` A map containing the relations between the jobs making up the partition.

### Fields inherited from class edu.isi.pegasus.planner.partitioner.DAXWriter

`mDaxFile, mLogger, mPartitionName, mPDAXDirectory, mWriteHandle, PACKAGE_NAME, PARTITION_PREFIX`

### Constructor Summary

Constructors
Constructor and Description
`MultipleLook(java.lang.String daxFile, java.lang.String directory)` The overloaded constructor.

### Method Summary

All Methods Instance Methods Concrete Methods
`boolean` `writePartitionDax(Partition partition, int index)` It writes out a dax consisting of the jobs as specified in the partition.

### Methods inherited from class edu.isi.pegasus.planner.partitioner.DAXWriter

`close, getPartitionName, getPDAXFilename, getPDAXFilename, initializeWriteHandle, initializeWriteHandle, loadInstance, loadInstance, setPartitionName, writeln, writePartitionDax`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Field Detail

#### mNodeSet

    private java.util.Set mNodeSet

The set of job id's in the partition.

#### mRelationsMap

    private java.util.Map mRelationsMap

A map containing the relations between the jobs making up the partition.

#### mPartADAG

    private org.griphyn.vdl.dax.ADAG mPartADAG

The ADAG object containing the partitioned dax.

#### mNumOfJobs

    private int mNumOfJobs

The number of jobs that are in the partition.

#### mCurrentNum

    private int mCurrentNum

The number of jobs about which the callback interface has knowledge.

#### mIndex

    private int mIndex

The index of the partition that is being written out.

### Constructor Detail

#### MultipleLook

    public MultipleLook(java.lang.String daxFile,
                        java.lang.String directory)

The overloaded constructor.

Parameters:
  `daxFile` - the path to the dax file that is being partitioned.
  `directory` - the directory in which the partitioned daxes are to be generated.

### Method Detail

#### writePartitionDax

    public boolean writePartitionDax(Partition partition,
                                     int index)

It writes out a dax consisting of the jobs as specified in the partition.

Specified by:
  `writePartitionDax` in class `DAXWriter`
Parameters:
  `partition` - the partition object containing the relations and id's of the jobs making up the partition.
  `index` - the index of the partition.
Returns:
  boolean true if dax successfully generated and written. false in case of error.