co-primitives 0.1.0

COKIT Primitives used throughout the `co-sdk` and `co-api` and Core implementations.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// SPDX-License-Identifier: AGPL-3.0-only
// Copyright (C) 2026 1io BRANDGUARDIAN GmbH

use crate::BlockStorage;
use futures::Stream;

pub trait Streamable<S>
where
	S: BlockStorage + Clone + 'static,
{
	type Item;
	type Stream: Stream<Item = Self::Item> + 'static;

	fn stream(&self, storage: S) -> Self::Stream;
}