|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.isi.pegasus.planner.visualize.spaceusage.Ploticus
public class Ploticus
An implementation that plots in the Ploticus format.
| Field Summary | |
|---|---|
static String |
DEFAULT_TIMING_UNITS
The default timing units. |
static String |
EMPTY_DIRECTORY_SIZE
The size of an empty directory as reported by du -s |
static String |
HOURS_TIMING_UNITS
The minutes unit for the x axis. |
private String |
mBasename
The basename of the files. |
private String |
mDirectory
The directory where the files are to be generated. |
static String |
MINUTES_TIMING_UNITS
The minutes unit for the x axis. |
private LogManager |
mLogger
The handle to the logging object. |
private NumberFormat |
mNumFormatter
The number formatter to format the float entries. |
private String |
mTimeUnits
The time units. |
private boolean |
mUseStatInfo
A boolean indicating whether to use stat info or not. |
| Fields inherited from interface edu.isi.pegasus.planner.visualize.spaceusage.Plot |
|---|
VERSION |
| Constructor Summary | |
|---|---|
Ploticus()
The default constructor. |
|
| Method Summary | |
|---|---|
protected String |
constructEntry(String job,
float time,
float clnup_size,
float no_clnup_size)
Returns an entry that needs to be plotted in the graph. |
private float |
convertFromSecondsTo(long time,
String units)
Converts from seconds to one of the units specified. |
void |
generateScriptFile(String name,
String dataFile,
String yUnits,
float maxTime,
float maxSpace)
Generates the script file required to give as input to ploticus. |
protected String |
getFilename(String site,
String suffix)
Returns the filename of the ploticus file to be generated. |
void |
initialize(String directory,
String basename,
boolean useStatInfo)
Initializer method. |
List |
plot(SpaceUsage su,
char unit,
String timeUnits)
Plot out the space usage. |
private boolean |
validTimeUnits(String units)
Returns a boolean indicating if a valid time unit or not. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String EMPTY_DIRECTORY_SIZE
public static final String DEFAULT_TIMING_UNITS
public static final String MINUTES_TIMING_UNITS
public static final String HOURS_TIMING_UNITS
private String mDirectory
private String mBasename
private boolean mUseStatInfo
private LogManager mLogger
private NumberFormat mNumFormatter
private String mTimeUnits
| Constructor Detail |
|---|
public Ploticus()
| Method Detail |
|---|
public void initialize(String directory,
String basename,
boolean useStatInfo)
initialize in interface Plotdirectory - the directory where the plots need to be generated.basename - the basename for the files that are generated.useStatInfo - boolean indicating whether to use stat info or not.
public List plot(SpaceUsage su,
char unit,
String timeUnits)
throws IOException
plot in interface Plotsu - the SpaceUsage.unit - the unit in which we need to plot. (K,M,G)timeUnits - the time unit.
IOException - in case of unable to write to the file.
public void generateScriptFile(String name,
String dataFile,
String yUnits,
float maxTime,
float maxSpace)
throws IOException
name - the path to the script file.dataFile - the path to corresponding data file.yUnits - the units for the space value.maxTime - the time in seconds.maxSpace - the maximum space.
IOException
protected String getFilename(String site,
String suffix)
site - the site handle.suffix - the suffix to be applied to the file.
protected String constructEntry(String job,
float time,
float clnup_size,
float no_clnup_size)
job - the name of the associated job.time - the timeclnup_size - the size with cleanupno_clnup_size - the size without cleanup
private float convertFromSecondsTo(long time,
String units)
time - the time.units - the units
private boolean validTimeUnits(String units)
units - the time unit.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||