1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at https://mozilla.org/MPL/2.0/.
// Copyright (c) 2026 2youg1 and the sprawling contributors
//! The two answers that read the Ledger back: a slice of the one
//! history, and one slice of a named range of it.
use ;
use ;
/// A slice of the one history, oldest first - the order the ledger
/// wrote them and the order a fold expects. A reader that wants the
/// newest first reverses a list it already has, and a server that
/// reversed it would make the fold the caller's problem.
// No `Eq`: an `EventRecord` carries a payload whose numbers may be
// floats, and the wire's other answers derive it only because none of
// them holds one.
/// One slice of a named range of ledger records, and where the slice
/// continues.
///
/// **The endpoints come back with the records.** The question that asked
/// for them carried no cursor a caller holds on to - not a `before` to
/// walk back from, but two seq numbers that may have arrived in a frame
/// the caller has already dropped - so an answer that did not name its
/// own slice could not be told from one for a different range, and a page
/// filling a gap while its record view is open would file the wrong
/// answer.
// No `Eq`, for the reason `HistoryAnswer` gives: a record's payload is
// arbitrary JSON.