|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.sdsc.inca.depot.persistent.PersistentObject edu.sdsc.inca.depot.persistent.InstanceInfo
public class InstanceInfo
Represents information specific to a particular instance of a reporter run.
Field Summary |
---|
Fields inherited from class edu.sdsc.inca.depot.persistent.PersistentObject |
---|
DB_EMPTY_STRING, MAX_DB_LONG_STRING_LENGTH, MAX_DB_STRING_LENGTH |
Constructor Summary | |
---|---|
InstanceInfo()
Default constructor. |
|
InstanceInfo(java.util.Date collected,
java.util.Date commited,
java.lang.Float memoryUsageMB,
java.lang.Float cpuUsageSec,
java.lang.Float wallClockTimeSec)
Full constructor. |
|
InstanceInfo(java.util.Date collected,
java.lang.String sysusage)
A constructor that parses the Inca protocol SYSUSAGE message. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object o)
Compares another object to this InstanceInfo for logical equality. |
PersistentObject |
fromBean(org.apache.xmlbeans.XmlObject o)
Copies information from an Inca schema XmlBean object so that this object contains equivalent information. |
java.util.Date |
getCollected()
Retrieve the time this instance was collected. |
java.util.Date |
getCommited()
Retrieve the time this instance was committed. |
java.lang.Float |
getCpuUsageSec()
get the cpu usage. |
java.lang.Long |
getId()
Retrieve the id -- null if not yet connected to database. |
java.lang.String |
getLog()
Retrieve the log of this InstanceInfo as an XML string. |
java.lang.Float |
getMemoryUsageMB()
Retrieve the memory usage. |
java.lang.Long |
getReportId()
Return the DB id of the report to which this instance is attached. |
java.lang.Float |
getWallClockTimeSec()
Get the length of time this reporter took to run. |
int |
hashCode()
Calculate a hash code using the same fields that where used in equals. |
void |
setCollected(java.util.Date collected)
Set the time this data was collected. |
void |
setCommited(java.util.Date commited)
set the thime this data was commited to db. |
void |
setCpuUsageSec(java.lang.Float cpuUsageSec)
Set the cup usage. |
void |
setId(java.lang.Long id)
Set the id. |
void |
setLog(java.lang.String log)
Set the log of this InstanceInfo. |
void |
setMemoryUsageMB(java.lang.Float memoryUsageMB)
Set the memory usage. |
void |
setReportId(java.lang.Long id)
Set the DB id of the report to which this instance is attached. |
void |
setWallClockTimeSec(java.lang.Float wallClockTimeSec)
Set the amount of time this reporter took to run. |
org.apache.xmlbeans.XmlObject |
toBean()
Returns a Inca schema XmlBean Limits object that contains information equivalent to this object. |
java.lang.String |
toXml()
Returns XML that represents the information in this object. |
Methods inherited from class edu.sdsc.inca.depot.persistent.PersistentObject |
---|
truncate |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public InstanceInfo()
public InstanceInfo(java.util.Date collected, java.util.Date commited, java.lang.Float memoryUsageMB, java.lang.Float cpuUsageSec, java.lang.Float wallClockTimeSec)
collected
- The time that the data was collectedcommited
- The time that the data was saved to the database.memoryUsageMB
- The amount of memory used by the reporter.cpuUsageSec
- The cpu used by this run of the reporterwallClockTimeSec
- The time the reporter took to run.public InstanceInfo(java.util.Date collected, java.lang.String sysusage)
collected
- The time that the date was collected.sysusage
- The Inca protocol SYSUSAGE message.Method Detail |
---|
public PersistentObject fromBean(org.apache.xmlbeans.XmlObject o)
fromBean
in class PersistentObject
o
- the XmlBean object to copy
public java.lang.Long getId()
public void setId(java.lang.Long id)
id
- The DB ID.public java.util.Date getCollected()
public void setCollected(java.util.Date collected)
collected
- date collectedpublic java.util.Date getCommited()
public void setCommited(java.util.Date commited)
commited
- commit timepublic java.lang.Float getMemoryUsageMB()
public void setMemoryUsageMB(java.lang.Float memoryUsageMB)
memoryUsageMB
- Memory usage in MBpublic java.lang.Float getCpuUsageSec()
public void setCpuUsageSec(java.lang.Float cpuUsageSec)
cpuUsageSec
- cpu usage in secpublic java.lang.Float getWallClockTimeSec()
public void setWallClockTimeSec(java.lang.Float wallClockTimeSec)
wallClockTimeSec
- time in secpublic java.lang.String getLog()
public void setLog(java.lang.String log)
log
- xml log of InstanceInfopublic java.lang.Long getReportId()
public void setReportId(java.lang.Long id)
id
- the DB id of this instance's reportpublic org.apache.xmlbeans.XmlObject toBean()
toBean
in class PersistentObject
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
o
- the object to compare
public java.lang.String toXml()
toXml
in class PersistentObject
public int hashCode()
hashCode
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |