Struct hdk::prelude::QueryFilter[][src]

#[non_exhaustive]pub struct QueryFilter {
    pub sequence_range: Option<Range<u32>>,
    pub entry_type: Option<EntryType>,
    pub header_type: Option<HeaderType>,
    pub include_entries: bool,
}

Query arguments

Fields (Non-exhaustive)

Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional Struct {{ .. }} syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.
sequence_range: Option<Range<u32>>

The range of source chain sequence numbers to match. Inclusive start, exclusive end.

entry_type: Option<EntryType>

Filter by EntryType

header_type: Option<HeaderType>

Filter by HeaderType

include_entries: bool

Include the entries in the elements

Implementations

impl ChainQueryFilter[src]

pub fn new() -> ChainQueryFilter[src]

Create a no-op ChainQueryFilter which returns everything

pub fn sequence_range(self, sequence_range: Range<u32>) -> ChainQueryFilter[src]

Filter on sequence range

pub fn entry_type(self, entry_type: EntryType) -> ChainQueryFilter[src]

Filter on entry type

pub fn header_type(self, header_type: HeaderType) -> ChainQueryFilter[src]

Filter on header type

pub fn include_entries(self, include_entries: bool) -> ChainQueryFilter[src]

Include the entries in the ElementsVec that is returned

pub fn check(&self, header: &Header) -> bool[src]

Perform the boolean check which this filter represents

Trait Implementations

impl Clone for ChainQueryFilter[src]

impl Debug for ChainQueryFilter[src]

impl Default for ChainQueryFilter[src]

impl<'de> Deserialize<'de> for ChainQueryFilter[src]

impl PartialEq<ChainQueryFilter> for ChainQueryFilter[src]

impl Serialize for ChainQueryFilter[src]

impl StructuralPartialEq for ChainQueryFilter[src]

impl<'_> TryFrom<&'_ ChainQueryFilter> for SerializedBytes[src]

type Error = SerializedBytesError

The type returned in the event of a conversion error.

impl TryFrom<ChainQueryFilter> for SerializedBytes[src]

type Error = SerializedBytesError

The type returned in the event of a conversion error.

impl TryFrom<SerializedBytes> for ChainQueryFilter[src]

type Error = SerializedBytesError

The type returned in the event of a conversion error.

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,