TestAsyncWorkerLoop class

A AsyncWorkerLoop for testing.

Inheritance
Implemented types

Constructors

TestAsyncWorkerLoop(AsyncWorkerConnection connection, {String? printMessage})

Properties

connection AsyncWorkerConnection
finalinherited
hashCode int
The hash code for this object.
no setterinherited
printMessage String?
If set, this message will be printed during the call to performRequest.
final
requests List<WorkRequest>
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

enqueueResponse(WorkResponse response) → void
Adds response to the queue. These will be returned from performResponse in the order they are added, otherwise it will throw if the queue is empty.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
performRequest(WorkRequest request) Future<WorkResponse>
Perform a single WorkRequest, and return a WorkResponse.
override
run() Future
Run the worker loop. The returned Future doesn't complete until connection#readRequest returns null.
inherited
toString() String
A string representation of this object.
inherited

Operators

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