uk.ac.soton.itinnovation.grid.service.types
Class Metric

java.lang.Object
  extended by uk.ac.soton.itinnovation.grid.service.types.Metric
All Implemented Interfaces:
Comparable<Metric>

public class Metric
extends Object
implements Comparable<Metric>


Field Summary
static Metric CPU
           
static String CPU_URI
           
static Metric CURRENT_ACTIVITIES
           
static String CURRENT_ACTIVITIES_URI
           
static Metric DATA_STAGER
           
static String DATA_STAGER_URI
           
static Metric DATA_TRANSFER
           
static String DATA_TRANSFER_URI
           
static Metric DISC
           
static String DISC_URI
           
static Metric JOB
           
static String JOB_URI
           
 MetricType type
           
 UnitType unitType
           
 
Constructor Summary
Metric()
           
Metric(String URI)
           
Metric(String URI, String description, String pluralDescription, String instantaneousDescription, String cumulativeDescription, String instantaneousUnits, String cumulativeUnits, MetricType type, UnitType unitType)
           
 
Method Summary
 void clean()
          Undefine (in place) fields that are the same as the automatically generated ones.
 Object clone()
           
 int compareTo(Metric m)
           
 boolean equals(Object obj)
           
 String getCumulativeDescription()
          Returns the cumulative desctiption of the metric.
 String getCumulativeUnits()
          Returns the cumulative units of the metric.
 String getDescription()
          Returns the human-readable metric description.
 Long getId()
           
 String getInstantaneousDescription()
          Returns the instantaneous description of the metric.
 String getInstantaneousUnits()
          Returns the instantaneous units of the metric.
 String getPluralDescription()
          Returns the plural description of the metric.
 String getType()
           
static TypeDesc getTypeDesc()
           
 String getUnitType()
           
 String getURI()
           
 int hashCode()
           
 boolean izCumulativeDescriptionDefined()
           
 boolean izCumulativeUnitsDefined()
           
 boolean izDescribed()
          Return whether any of the description fields have been set.
 boolean izDescriptionDefined()
          Returns whether the description field is defined (the alternative being auto-generated from the URI).
 boolean izInstantaneousDescriptionDefined()
           
 boolean izInstantaneousUnitsDefined()
           
 boolean izInstantanousUnitsDefined()
          Deprecated. 
 boolean izPluralDescriptionDefined()
           
 void setCumulativeDescription(String argDescription)
           
 void setCumulativeUnits(String argUnits)
           
 void setDescription(String argDescription)
           
 void setId(Long argId)
           
 void setInstantaneousDescription(String argDescription)
           
 void setInstantaneousUnits(String argUnits)
           
 void setPluralDescription(String argDescription)
           
 void setType(String argType)
           
 void setUnitType(String argType)
           
 void setURI(String argURI)
           
 String toString()
          
 void update(Metric m)
           
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

type

public MetricType type

unitType

public UnitType unitType

CURRENT_ACTIVITIES_URI

public static final String CURRENT_ACTIVITIES_URI
See Also:
Constant Field Values

JOB_URI

public static final String JOB_URI
See Also:
Constant Field Values

DATA_STAGER_URI

public static final String DATA_STAGER_URI
See Also:
Constant Field Values

CPU_URI

public static final String CPU_URI
See Also:
Constant Field Values

DISC_URI

public static final String DISC_URI
See Also:
Constant Field Values

DATA_TRANSFER_URI

public static final String DATA_TRANSFER_URI
See Also:
Constant Field Values

CURRENT_ACTIVITIES

public static final Metric CURRENT_ACTIVITIES

JOB

public static final Metric JOB

DATA_STAGER

public static final Metric DATA_STAGER

CPU

public static final Metric CPU

DISC

public static final Metric DISC

DATA_TRANSFER

public static final Metric DATA_TRANSFER
Constructor Detail

Metric

public Metric()

Metric

public Metric(String URI)

Metric

public Metric(String URI,
              String description,
              String pluralDescription,
              String instantaneousDescription,
              String cumulativeDescription,
              String instantaneousUnits,
              String cumulativeUnits,
              MetricType type,
              UnitType unitType)
Method Detail

getId

public Long getId()

setId

public void setId(Long argId)

getURI

public String getURI()

setURI

public void setURI(String argURI)

getDescription

public String getDescription()
Returns the human-readable metric description. Defaults to the last element of the URI (following the last "/").


setDescription

public void setDescription(String argDescription)

izDescriptionDefined

public boolean izDescriptionDefined()
Returns whether the description field is defined (the alternative being auto-generated from the URI). Named "izDescriptionDefined" instead of "isDescriptionDefined" to avoid serialisation by Axis.


getPluralDescription

public String getPluralDescription()
Returns the plural description of the metric. Defaults to the description with an added "s".


setPluralDescription

public void setPluralDescription(String argDescription)

izPluralDescriptionDefined

public boolean izPluralDescriptionDefined()

getInstantaneousDescription

public String getInstantaneousDescription()
Returns the instantaneous description of the metric. Defaults to "number of " plus the plural description.


setInstantaneousDescription

public void setInstantaneousDescription(String argDescription)

izInstantaneousDescriptionDefined

public boolean izInstantaneousDescriptionDefined()

getCumulativeDescription

public String getCumulativeDescription()
Returns the cumulative desctiption of the metric. Defaults to the description plus " time".


setCumulativeDescription

public void setCumulativeDescription(String argDescription)

izCumulativeDescriptionDefined

public boolean izCumulativeDescriptionDefined()

getInstantaneousUnits

public String getInstantaneousUnits()
Returns the instantaneous units of the metric. If the cumulative units are defined then will default to cumulative units plus "/s", otherwise defaults to "".


setInstantaneousUnits

public void setInstantaneousUnits(String argUnits)

izInstantanousUnitsDefined

@Deprecated
public boolean izInstantanousUnitsDefined()
Deprecated. 


izInstantaneousUnitsDefined

public boolean izInstantaneousUnitsDefined()

getCumulativeUnits

public String getCumulativeUnits()
Returns the cumulative units of the metric. If the instantaneous units are defined then will default to the instantaneous units plus ".s", otherwise defaults to "".


setCumulativeUnits

public void setCumulativeUnits(String argUnits)

izCumulativeUnitsDefined

public boolean izCumulativeUnitsDefined()

getType

public String getType()

setType

public void setType(String argType)

getUnitType

public String getUnitType()

setUnitType

public void setUnitType(String argType)

izDescribed

public boolean izDescribed()
Return whether any of the description fields have been set.


toString

public String toString()

Overrides:
toString in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

compareTo

public int compareTo(Metric m)
Specified by:
compareTo in interface Comparable<Metric>

clone

public Object clone()
Overrides:
clone in class Object

getTypeDesc

public static TypeDesc getTypeDesc()

clean

public void clean()
Undefine (in place) fields that are the same as the automatically generated ones.


update

public void update(Metric m)


Copyright © 2001-2008 University of Southampton IT Innovation Centre. All Rights Reserved.