public final class ProcessingProfiler extends Object
| Modifier and Type | Field and Description |
|---|---|
protected static boolean |
debugState
boolean flag controlling whether diagnostics time-marks are taken or the
routine to be skipped
|
protected static boolean |
loggerOutput
boolean flag controlling whether the statistics/time differences are
output to the logger/console or not
|
protected static boolean |
verboseOutput
boolean flag controlling whether the statistics/time differences are
output to the logger/console or not
|
| Modifier and Type | Method and Description |
|---|---|
static String |
getCallingClassMethod(int recursionDepth) |
protected static String |
getCallingClassMethod(String msg) |
static boolean |
getDebugState() |
static boolean |
getLoggerOutputState() |
static long |
getTimeDiff(long lastStamp) |
static long |
getTimeDiff(long lastStamp,
String msg) |
static long |
getTimeStamp()
Returns the current value of the running Java Virtual Machine's
high-resolution time source, in nanoseconds.
|
static boolean |
getVerboseOutputState() |
static void |
setDebugState(boolean state)
boolean flag controlling whether diagnostics time-marks are taken or the
routine to be skipped
|
static void |
setLoggerOutputState(boolean state)
boolean flag controlling whether the statistics/time differences are
output to the logger/console or not
|
static void |
setVerboseOutputState(boolean state)
boolean flag controlling whether the statistics/time differences are
output to the logger/console or not
|
protected static boolean debugState
protected static boolean verboseOutput
protected static boolean loggerOutput
public static void setDebugState(boolean state)
state - true: enablepublic static boolean getDebugState()
public static void setVerboseOutputState(boolean state)
state - true: enablepublic static boolean getVerboseOutputState()
public static void setLoggerOutputState(boolean state)
state - true: enablepublic static boolean getLoggerOutputState()
public static long getTimeStamp()
This method can only be used to measure elapsed time and is not related to any other notion of system or wall-clock time. The value returned represents nanoseconds since some fixed but arbitrary origin time.
the overhead of taking the time stamp is disabled via #debugProperty()
public static long getTimeDiff(long lastStamp)
lastStamp - reference time stamppublic static String getCallingClassMethod(int recursionDepth)
recursionDepth - 0 being the calling functionpublic static long getTimeDiff(long lastStamp,
String msg)
lastStamp - reference time stampmsg - custom string message that should be printed alongside the time stampCopyright © 2019 GSI Helmholtzzentrum für Schwerionenforschung GmbH. All rights reserved.