substreams_ethereum_core/pb/sf.ethereum.transform.v1.rs
1// @generated
2/// CombinedFilter is a combination of "LogFilters" and "CallToFilters"
3///
4/// It transforms the requested stream in two ways:
5/// 1. STRIPPING
6/// The block data is stripped from all transactions that don't
7/// match any of the filters.
8///
9/// 2. SKIPPING
10/// If an "block index" covers a range containing a
11/// block that does NOT match any of the filters, the block will be
12/// skipped altogether, UNLESS send_all_block_headers is enabled
13/// In that case, the block would still be sent, but without any
14/// transactionTrace
15///
16/// The SKIPPING feature only applies to historical blocks, because
17/// the "block index" is always produced after the merged-blocks files
18/// are produced. Therefore, the "live" blocks are never filtered out.
19///
20#[allow(clippy::derive_partial_eq_without_eq)]
21#[derive(Clone, PartialEq, ::prost::Message)]
22pub struct CombinedFilter {
23 #[prost(message, repeated, tag = "1")]
24 pub log_filters: ::prost::alloc::vec::Vec<LogFilter>,
25 #[prost(message, repeated, tag = "2")]
26 pub call_filters: ::prost::alloc::vec::Vec<CallToFilter>,
27 /// Always send all blocks. if they don't match any log_filters or call_filters,
28 /// all the transactions will be filtered out, sending only the header.
29 #[prost(bool, tag = "3")]
30 pub send_all_block_headers: bool,
31}
32/// MultiLogFilter concatenates the results of each LogFilter (inclusive OR)
33#[allow(clippy::derive_partial_eq_without_eq)]
34#[derive(Clone, PartialEq, ::prost::Message)]
35pub struct MultiLogFilter {
36 #[prost(message, repeated, tag = "1")]
37 pub log_filters: ::prost::alloc::vec::Vec<LogFilter>,
38}
39/// LogFilter will match calls where *BOTH*
40/// * the contract address that emits the log is one in the provided addresses -- OR addresses list is empty --
41/// * the event signature (topic.0) is one of the provided event_signatures -- OR event_signatures is empty --
42///
43/// a LogFilter with both empty addresses and event_signatures lists is invalid and will fail.
44#[allow(clippy::derive_partial_eq_without_eq)]
45#[derive(Clone, PartialEq, ::prost::Message)]
46pub struct LogFilter {
47 #[prost(bytes = "vec", repeated, tag = "1")]
48 pub addresses: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
49 /// corresponds to the keccak of the event signature which is stores in topic.0
50 #[prost(bytes = "vec", repeated, tag = "2")]
51 pub event_signatures: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
52}
53/// MultiCallToFilter concatenates the results of each CallToFilter (inclusive OR)
54#[allow(clippy::derive_partial_eq_without_eq)]
55#[derive(Clone, PartialEq, ::prost::Message)]
56pub struct MultiCallToFilter {
57 #[prost(message, repeated, tag = "1")]
58 pub call_filters: ::prost::alloc::vec::Vec<CallToFilter>,
59}
60/// CallToFilter will match calls where *BOTH*
61/// * the contract address (TO) is one in the provided addresses -- OR addresses list is empty --
62/// * the method signature (in 4-bytes format) is one of the provided signatures -- OR signatures is empty --
63///
64/// a CallToFilter with both empty addresses and signatures lists is invalid and will fail.
65#[allow(clippy::derive_partial_eq_without_eq)]
66#[derive(Clone, PartialEq, ::prost::Message)]
67pub struct CallToFilter {
68 #[prost(bytes = "vec", repeated, tag = "1")]
69 pub addresses: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
70 #[prost(bytes = "vec", repeated, tag = "2")]
71 pub signatures: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
72}
73/// HeaderOnly returns only the block's header and few top-level core information for the block. Useful
74/// for cases where no transactions information is required at all.
75///
76/// The structure that would will have access to after:
77///
78/// ```ignore
79/// Block {
80/// int32 ver = 1;
81/// bytes hash = 2;
82/// uint64 number = 3;
83/// uint64 size = 4;
84/// BlockHeader header = 5;
85/// }
86/// ```
87///
88/// Everything else will be empty.
89#[allow(clippy::derive_partial_eq_without_eq)]
90#[derive(Clone, PartialEq, ::prost::Message)]
91pub struct HeaderOnly {}
92// @@protoc_insertion_point(module)