Package edu.umd.cs.findbugs
Class Footprint
- java.lang.Object
-
- edu.umd.cs.findbugs.Footprint
-
public class Footprint extends java.lang.Object
Class to maintain a snapshot of a processes's time and memory usage. This uses some JDK 1.5 APIs so must be careful that it doesn't cause any harm when run from 1.4.- See Also:
FindBugs
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Footprint.CollectionBeanWrapper
Wrapper so that possible NoClassDefFoundError can be caught.static class
Footprint.MemoryBeanWrapper
Wrapper so that possible NoClassDefFoundError can be caught.static class
Footprint.OperatingSystemBeanWrapper
Wrapper so that possible NoClassDefFoundError can be caught.
-
Field Summary
Fields Modifier and Type Field Description private static int
CLASSCAST_ERROR
private long
clockTime
private long
collectionTime
private long
cpuTime
private static int
ERROR_ERROR
private static int
NOCLASSDEF_ERROR
private long
peakMem
private static int
RUNTIME_EXCEPTION
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description long
getClockTime()
long
getCollectionTime()
long
getCpuTime()
long
getPeakMemory()
static void
main(java.lang.String[] argv)
private void
pullData()
java.lang.String
toString()
-
-
-
Field Detail
-
NOCLASSDEF_ERROR
private static final int NOCLASSDEF_ERROR
- See Also:
- Constant Field Values
-
CLASSCAST_ERROR
private static final int CLASSCAST_ERROR
- See Also:
- Constant Field Values
-
ERROR_ERROR
private static final int ERROR_ERROR
- See Also:
- Constant Field Values
-
RUNTIME_EXCEPTION
private static final int RUNTIME_EXCEPTION
- See Also:
- Constant Field Values
-
cpuTime
private long cpuTime
-
clockTime
private long clockTime
-
peakMem
private long peakMem
-
collectionTime
private long collectionTime
-
-
Constructor Detail
-
Footprint
public Footprint()
-
Footprint
public Footprint(Footprint base)
uses deltas from base for cpuTime and clockTime (but not peakMemory)
-
-
Method Detail
-
pullData
private void pullData()
-
getCpuTime
public long getCpuTime()
-
getClockTime
public long getClockTime()
-
getPeakMemory
public long getPeakMemory()
-
getCollectionTime
public long getCollectionTime()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
main
public static void main(java.lang.String[] argv)
-
-