Type Alias Topic
pub type Topic = FilterSet<FixedBytes<32>>;
Expand description
A single topic
Aliased Type§
struct Topic(/* private fields */);
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 40 bytes
Implementations
§impl<T> FilterSet<T>
impl<T> FilterSet<T>
pub fn to_value_or_array(&self) -> Option<ValueOrArray<T>>
pub fn to_value_or_array(&self) -> Option<ValueOrArray<T>>
Returns a ValueOrArray inside an Option, so that:
- If the filter is empty, it returns None
- If the filter has only 1 value, it returns the single value
- Otherwise it returns an array of values
§impl<T> FilterSet<T>
impl<T> FilterSet<T>
§impl<T> FilterSet<T>
impl<T> FilterSet<T>
pub fn to_bloom_filter(&self) -> BloomFilter
pub fn to_bloom_filter(&self) -> BloomFilter
Returns a list of Bloom (BloomFilter) corresponding to the filter’s values
Trait Implementations
§impl<'de, T> Deserialize<'de> for FilterSet<T>
impl<'de, T> Deserialize<'de> for FilterSet<T>
§fn deserialize<__D>(
__deserializer: __D,
) -> Result<FilterSet<T>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<FilterSet<T>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
§impl From<Uint<256, 4>> for FilterSet<FixedBytes<32>>
impl From<Uint<256, 4>> for FilterSet<FixedBytes<32>>
§fn from(src: Uint<256, 4>) -> FilterSet<FixedBytes<32>>
fn from(src: Uint<256, 4>) -> FilterSet<FixedBytes<32>>
Converts to this type from the input type.
§impl<T> From<ValueOrArray<Option<T>>> for FilterSet<T>
impl<T> From<ValueOrArray<Option<T>>> for FilterSet<T>
§fn from(src: ValueOrArray<Option<T>>) -> FilterSet<T>
fn from(src: ValueOrArray<Option<T>>) -> FilterSet<T>
Converts to this type from the input type.
§impl<T> From<ValueOrArray<T>> for FilterSet<T>
impl<T> From<ValueOrArray<T>> for FilterSet<T>
§fn from(src: ValueOrArray<T>) -> FilterSet<T>
fn from(src: ValueOrArray<T>) -> FilterSet<T>
Converts to this type from the input type.
§impl<T> FromIterator<T> for FilterSet<T>
impl<T> FromIterator<T> for FilterSet<T>
§fn from_iter<I>(iter: I) -> FilterSet<T>where
I: IntoIterator<Item = T>,
fn from_iter<I>(iter: I) -> FilterSet<T>where
I: IntoIterator<Item = T>,
Creates a value from an iterator. Read more