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
use Arc;
use ;
/// Custom Block Size
///
/// In channels, items are stored in contiguous blocks (chunks) of item slots.
/// New blocks are allocated as items are sent through the channel.
/// A large block size will result in less but bigger allocations.
/// A small block size will result in more, smaller allocations.
/// For channels transporting large amounts of items, a large block size is preferred.
/// This structure allows you to create channels with custom block size (chunk length).
///
/// See the following pre-defined block sizes:
/// - [`SmallBlockSize`]: 8 slots per block
/// - [`DefaultBlockSize`]: 32 slots per block
/// - [`LargeBlockSize`]: 4096 slots per block
/// - [`HugeBlockSize`]: 1048576 slots per block
///
/// L must be equal to F x 8
;
/// Block size suitable for sending items one by one, from time to time
///
/// Each block will have 8 slots.
pub type SmallBlockSize = ;
/// Reasonable default block size
///
/// Each block will have 32 slots.
pub type DefaultBlockSize = ;
/// Block size suitable for batch sending of many items
///
/// Each block will have 4096 slots.
pub type LargeBlockSize = ;
/// Block size suitable for batch sending of tons of items
///
/// Each block will have 1 048 576 slots.
pub type HugeBlockSize = ;