public static class ProcessData.Measurements extends java.lang.Object implements IMeasurements
| Modifier and Type | Field and Description |
|---|---|
private double |
avgLoad
Stores the average load collected during monitoring.
|
private double |
avgMemUse
Stores the average memory use collected during monitoring.
|
private long |
ioRead
Stores the amount of bytes read from I/O.
|
private long |
ioWrite
Stores the amount of bytes written to I/O.
|
private double |
load
Stores the actual load.
|
private double |
maxLoad
Stores the maximum load collected during monitoring.
|
private long |
maxMemUse
Stores the maximum memory use collected during monitoring.
|
private double |
memUse
Stores the actual memory use.
|
private double |
minLoad
Stores the minimum load collected during monitoring.
|
private long |
minMemUse
Stores the minimum memory use collected during monitoring.
|
private int |
status
Stores the data acquisition status for this process.
|
private long |
systemTime
Stores the system time consumed by the process.
|
STATUS_FILE, STATUS_NET| Constructor and Description |
|---|
Measurements()
Creates a new instance and initializes the attributes.
|
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
Clears this instance.
|
void |
copyFrom(ProcessData.Measurements measurements)
Copies all values from the given
measurements instance. |
double |
getActMemUse()
Returns the actual memory usage.
|
double |
getAvgLoad()
Returns the average load.
|
double |
getAvgMemUse()
Returns the average memory usage.
|
long |
getIoRead()
Returns the number of bytes read from external input.
|
long |
getIoWrite()
Returns the number of bytes written to external input.
|
double |
getLoad()
Returns the actual load.
|
double |
getMaxLoad()
Returns the maximum load.
|
long |
getMaxMemUse()
Returns the maximum memory usage.
|
double |
getMinLoad()
Returns the minimum load.
|
long |
getMinMemUse()
Returns the minimum memory usage.
|
int |
getStatus()
Returns the status flags as combination of
of
IMeasurements.STATUS_FILE,
IMeasurements.STATUS_NET. |
long |
getSystemTime()
Returns the duration of the process in system time.
|
void |
read(java.io.DataInputStream in)
Reads data of this instance from the given input stream.
|
void |
send(java.io.DataOutputStream out)
Sends the stored data to the output stream.
|
void |
setAvgLoad(double avgLoad)
Changes the average load value.
|
void |
setAvgMemUse(double avgMemUse)
Changes the average memory usage value.
|
void |
setMinMaxLoad(double load)
Changes minimum and maximum load values at once (calculates
minimum and maximum compared with stored values).
|
void |
setMinMaxMemUse(long use)
Changes minimum and maximum memory usage values at once (calculates
minimum and maximum compared with stored values).
|
void |
setStatus(int status)
Changes the status flags as combination of
of
IMeasurements.STATUS_FILE,
IMeasurements.STATUS_NET. |
private double minLoad
private double avgLoad
private double load
private double maxLoad
private long minMemUse
private double avgMemUse
private double memUse
private long maxMemUse
private long systemTime
private long ioRead
private long ioWrite
private int status
IMeasurements.STATUS_FILE,
IMeasurements.STATUS_NET.Measurements()
public void clear()
public void copyFrom(ProcessData.Measurements measurements)
measurements instance.measurements - the instance to copy frompublic void setMinMaxLoad(double load)
load - the new load valuepublic void setAvgLoad(double avgLoad)
avgLoad - the average load valuepublic void setMinMaxMemUse(long use)
use - the current number of bytes allocatedpublic void setStatus(int status)
IMeasurements.STATUS_FILE,
IMeasurements.STATUS_NET.status - the new statusFlagspublic int getStatus()
IMeasurements.STATUS_FILE,
IMeasurements.STATUS_NET.getStatus in interface IMeasurementsFlagspublic void setAvgMemUse(double avgMemUse)
avgMemUse - the average number of bytes allocatedpublic double getMinLoad()
getMinLoad in interface IMeasurementspublic double getAvgLoad()
getAvgLoad in interface IMeasurementspublic double getMaxLoad()
getMaxLoad in interface IMeasurementspublic long getMinMemUse()
getMinMemUse in interface IMeasurementspublic double getAvgMemUse()
getAvgMemUse in interface IMeasurementspublic long getMaxMemUse()
getMaxMemUse in interface IMeasurementspublic long getSystemTime()
getSystemTime in interface IMeasurementspublic long getIoRead()
getIoRead in interface IMeasurementspublic long getIoWrite()
getIoWrite in interface IMeasurementspublic void send(java.io.DataOutputStream out)
throws java.io.IOException
out - the stream where to write the data tojava.io.IOException - in case of any I/O problempublic void read(java.io.DataInputStream in)
throws java.io.IOException
in - the input stream from where to read data fromjava.io.IOException - in case of any I/O problempublic double getLoad()
IMeasurementsgetLoad in interface IMeasurementspublic double getActMemUse()
IMeasurementsgetActMemUse in interface IMeasurements