ProtocolExample class final

One exchange of the protocol: a request and what the engine answers.

Constructors

ProtocolExample(String title, Map<String, Object?> request, {Map<String, Object?>? ok, String? errorCode})
An example titled title; exactly one of ok and errorCode is set.
const

Properties

answer → Map<String, Object?>
The answer as the wire shows it.
no setter
errorCode → String?
The code of an error answer (its message is free text).
final
hashCode → int
The hash code for this object.
no setterinherited
markdown → String
The example as it appears in PROTOCOL.md.
no setter
ok → Map<String, Object?>?
The ok payload of the answer. The string ProtocolExamples.any matches any value, and a placeholder (ProtocolExamples.transaction, ProtocolExamples.lease, ProtocolExamples.mutation, ProtocolExamples.conflict) captures the value at its place, which later requests reuse.
final
request → Map<String, Object?>
The request, as sent on the wire.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
title → String
What it shows.
final

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