Trait xso::AsXml

source ·
pub trait AsXml {
    type ItemIter<'x>: Iterator<Item = Result<Item<'x>, Error>>
       where Self: 'x;

    // Required method
    fn as_xml_iter(&self) -> Result<Self::ItemIter<'_>, Error>;
}
Expand description

Trait allowing to iterate a struct’s contents as serialisable Items.

Important: Changing the ItemIter associated type is considered a non-breaking change for any given implementation of this trait. Always refer to a type’s iterator type using fully-qualified notation, for example: <T as xso::AsXml>::ItemIter.

Required Associated Types§

source

type ItemIter<'x>: Iterator<Item = Result<Item<'x>, Error>> where Self: 'x

The iterator type.

Important: Changing this type is considered a non-breaking change for any given implementation of this trait. Always refer to a type’s iterator type using fully-qualified notation, for example: <T as xso::AsXml>::ItemIter.

Required Methods§

source

fn as_xml_iter(&self) -> Result<Self::ItemIter<'_>, Error>

Return an iterator which emits the contents of the struct or enum as serialisable Item items.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl AsXml for Element

Available on crate feature minidom only.
§

type ItemIter<'a> = ElementAsXml<'a>

source§

fn as_xml_iter(&self) -> Result<Self::ItemIter<'_>, Error>

source§

impl<T: AsXml> AsXml for Option<T>

§

type ItemIter<'x> = OptionAsXml<<T as AsXml>::ItemIter<'x>> where T: 'x

source§

fn as_xml_iter(&self) -> Result<Self::ItemIter<'_>, Error>

source§

impl<T: AsXml> AsXml for Box<T>

§

type ItemIter<'x> = BoxAsXml<<T as AsXml>::ItemIter<'x>> where T: 'x

source§

fn as_xml_iter(&self) -> Result<Self::ItemIter<'_>, Error>

Implementors§

impl AsXml for ChatState

impl AsXml for Header

impl AsXml for MoodEnum

impl AsXml for Actor

impl AsXml for Status

impl AsXml for Attention

impl AsXml for Data

impl AsXml for Info

impl AsXml for Metadata

impl AsXml for Blocked

impl AsXml for Data

impl AsXml for Conference

impl AsXml for Storage

impl AsXml for Url

impl AsXml for Disable

impl AsXml for Enable

impl AsXml for Private

impl AsXml for Received

impl AsXml for Sent

impl AsXml for Append

impl AsXml for Cert

impl AsXml for Disable

impl AsXml for Item

impl AsXml for Name

impl AsXml for Resource

impl AsXml for Revoke

impl AsXml for Users

impl AsXml for Handshake

impl AsXml for Active

impl AsXml for Feature

impl AsXml for Inactive

impl AsXml for DataForm

impl AsXml for Option_

impl AsXml for ListRange

impl AsXml for Delay

impl AsXml for Feature

impl AsXml for Identity

impl AsXml for Item

impl AsXml for ECaps2

impl AsXml for Service

impl AsXml for FastQuery

impl AsXml for Mechanism

impl AsXml for Token

impl AsXml for Forwarded

impl AsXml for Hash

impl AsXml for Get

impl AsXml for Put

impl AsXml for SlotResult

impl AsXml for Close

impl AsXml for Data

impl AsXml for Open

impl AsXml for Idle

impl AsXml for Content

impl AsXml for Range

impl AsXml for Received

impl AsXml for Content

impl AsXml for Group

impl AsXml for Transport

impl AsXml for Candidate

impl AsXml for Transport

impl AsXml for Candidate

impl AsXml for Transport

impl AsXml for RtcpFb

impl AsXml for Parameter

impl AsXml for RtcpMux

impl AsXml for RtpHdrext

impl AsXml for Candidate

impl AsXml for Group

impl AsXml for Parameter

impl AsXml for Source

impl AsXml for Thumbnail

impl AsXml for Bundle

impl AsXml for Device

impl AsXml for DeviceList

impl AsXml for Encrypted

impl AsXml for Header

impl AsXml for IV

impl AsXml for Key

impl AsXml for Payload

impl AsXml for Prekeys

impl AsXml for End

impl AsXml for Fin

impl AsXml for Result_

impl AsXml for Start

impl AsXml for Uri

impl AsXml for Body

impl AsXml for Subject

impl AsXml for Thread

impl AsXml for Replace

impl AsXml for Create

impl AsXml for Destroy

impl AsXml for Join

impl AsXml for Leave

impl AsXml for Mix

impl AsXml for SetNick

impl AsXml for Subscribe

impl AsXml for Text

impl AsXml for History

impl AsXml for Muc

impl AsXml for Continue

impl AsXml for Item

impl AsXml for MucUser

impl AsXml for Reason

impl AsXml for Nick

impl AsXml for OccupantId

impl AsXml for Oob

impl AsXml for PubKey

impl AsXml for PubKeyData

impl AsXml for PubKeyMeta

impl AsXml for Ping

impl AsXml for Query

impl AsXml for Item

impl AsXml for Configure

impl AsXml for Default

impl AsXml for Delete

impl AsXml for Purge

impl AsXml for Redirect

impl AsXml for Configure

impl AsXml for Create

impl AsXml for Default

impl AsXml for Item

impl AsXml for Items

impl AsXml for Options

impl AsXml for Publish

impl AsXml for Retract

impl AsXml for Subscribe

impl AsXml for Reaction

impl AsXml for Reactions

impl AsXml for Received

impl AsXml for Request

impl AsXml for Group

impl AsXml for Item

impl AsXml for Roster

impl AsXml for SetQuery

impl AsXml for SetResult

impl AsXml for Insert

impl AsXml for Wait

impl AsXml for Abort

impl AsXml for Auth

impl AsXml for Challenge

impl AsXml for Response

impl AsXml for Success

impl AsXml for A

impl AsXml for Enable

impl AsXml for Enabled

impl AsXml for Failed

impl AsXml for R

impl AsXml for Resume

impl AsXml for Resumed

impl AsXml for OriginId

impl AsXml for StanzaId

impl AsXml for Stream

impl AsXml for Bind

impl AsXml for StartTls

impl AsXml for TimeQuery

impl AsXml for Artist

impl AsXml for Length

impl AsXml for Rating

impl AsXml for Source

impl AsXml for Title

impl AsXml for Track

impl AsXml for Tune

impl AsXml for Uri

impl AsXml for Binval

impl AsXml for Photo

impl AsXml for Type

impl AsXml for Photo

impl AsXml for Open