BenchContext class

Context that is passed to a benchmarked function. The instance is shared between iterations of the benchmark. Its methods can be used for example to override of the measured portion of the function.

Available extensions
Annotations
  • @JS()
  • @staticInterop
  • @anonymous

Constructors

BenchContext({String? name, String? origin, void start()?, void end()?})
factory

Properties

end ↔ void Function()

Available on BenchContext, provided by the BenchContext$Typings extension

getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
name String

Available on BenchContext, provided by the BenchContext$Typings extension

The current benchmark name.
getter/setter pair
origin String

Available on BenchContext, provided by the BenchContext$Typings extension

The string URL of the current benchmark.
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
start ↔ void Function()

Available on BenchContext, provided by the BenchContext$Typings extension

getter/setter pair

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited