render_tree

Trait IterBlockComponent

Source
pub trait IterBlockComponent: Sized {
    type Item;

    // Required method
    fn append(
        self,
        block: impl FnMut(Self::Item, Document) -> Document,
        document: Document,
    ) -> Document;

    // Provided method
    fn with<F: FnMut(Self::Item, Document) -> Document>(
        component: Self,
        block: F,
    ) -> CurriedIterBlockComponent<Self, F> { ... }
}

Required Associated Types§

Required Methods§

Source

fn append( self, block: impl FnMut(Self::Item, Document) -> Document, document: Document, ) -> Document

Provided Methods§

Source

fn with<F: FnMut(Self::Item, Document) -> Document>( component: Self, block: F, ) -> CurriedIterBlockComponent<Self, F>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<'item, U, Iterator> IterBlockComponent for Join<U, Iterator>
where Iterator: IntoIterator<Item = U>,

Source§

type Item = U

Source§

impl<U, Iterator: IntoIterator<Item = U>> IterBlockComponent for Each<U, Iterator>

Source§

type Item = U