public class Benchmark
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
Benchmark.Statistician
Collects statistics for a test that is run multiple times.
|
Modifier and Type | Field and Description |
---|---|
private Function1<Benchmark.Statistician,java.lang.Void> |
function |
static org.slf4j.Logger |
LOGGER
Certain tests are enabled only if logging is enabled at debug level or
higher.
|
private int |
repeat |
private Benchmark.Statistician |
statistician |
Constructor and Description |
---|
Benchmark(java.lang.String description,
Function1<Benchmark.Statistician,java.lang.Void> function,
int repeat) |
Modifier and Type | Method and Description |
---|---|
static boolean |
enabled()
Returns whether performance tests are enabled.
|
(package private) static long |
printDuration(java.lang.String desc,
long t0) |
void |
run() |
public static final org.slf4j.Logger LOGGER
private final Function1<Benchmark.Statistician,java.lang.Void> function
private final int repeat
private final Benchmark.Statistician statistician
public Benchmark(java.lang.String description, Function1<Benchmark.Statistician,java.lang.Void> function, int repeat)
Copyright © 2012–2019 The Apache Software Foundation. All rights reserved.