|
GATE Version 3.1-2270 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgate.util.profile.Profiler
public class Profiler
Constructor Summary | |
---|---|
Profiler()
|
Method Summary | |
---|---|
String |
checkPoint(String execPointDescr)
To be called at all execution points of interest. |
String |
checkPoint(String execPointDescr,
String[] categories,
boolean showDescr,
boolean showStats,
boolean memoryCheck)
In addition to the variant of the method with two parameters allows: a set of categories (identified by strings) to which the preceeding fragment of code belongs; flag determining whether the description of the execution point to be displayed; flag determining whether the statistics to be shown |
void |
enable(boolean isEnabled)
Switches the profiler ON and OFF. |
void |
enableGCCalling(boolean collect)
Tell's the profiler whether to call the garbage collector when detecting memory usage or not. |
long |
getCategoryTimeLast(String category)
Returns 0 if the category was not found |
long |
getCategoryTimeSum(String category)
Returns 0 if the category was not found |
long |
getNetRunTime()
Returns the time spend in the last run without the time spend by the profiler. |
long |
getProfilerTime()
Returns the time spend by the profiler during the last run. |
long |
getRunDuration()
Returns the time spend in the current run until the last check-point inclusive the time spend by the profiler. |
String |
initRun(String runDescription)
Inialises the profiler for a new run |
boolean |
isEnabled()
Answers is the profiler switched ON or OFF. |
boolean |
isGCCallingEnabled()
|
void |
printCategAvg(String categ,
long items,
double volume,
String whateverMeasure)
An auxiliary routine printing time, avg. time, and avg. speed for a category |
String |
printSpeed(long timeMillis,
double whatever,
String whateverMeasure)
An auxiliary routine printing in a string speed |
String |
printTime(long timeMillis)
An auxiliary routine printing time in "nnn.nns" format |
void |
printToSystemOut(boolean doPrint)
Sets the profiler to print (or not) to the standard output. |
void |
showCategoryTime(String categ)
Prints the time for certain category of activities |
void |
showCategoryTimes()
Prints the time for all the categories of activities |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Profiler()
Method Detail |
---|
public void enable(boolean isEnabled)
public boolean isEnabled()
public void enableGCCalling(boolean collect)
public boolean isGCCallingEnabled()
enableGCCalling(boolean)
public long getProfilerTime()
public long getNetRunTime()
public long getRunDuration()
public String initRun(String runDescription)
public String checkPoint(String execPointDescr)
public String checkPoint(String execPointDescr, String[] categories, boolean showDescr, boolean showStats, boolean memoryCheck)
public long getCategoryTimeSum(String category)
public long getCategoryTimeLast(String category)
public void showCategoryTimes()
public void showCategoryTime(String categ)
public String printTime(long timeMillis)
public String printSpeed(long timeMillis, double whatever, String whateverMeasure)
public void printCategAvg(String categ, long items, double volume, String whateverMeasure)
public void printToSystemOut(boolean doPrint)
doPrint
- whether or not to print to std out.
|
GATE Version 3.1-2270 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |