fn add_conditions<W: Write>(&self, writer: &mut EventWriter<W>) {
        // start conditions statement
        write_event(
            XmlEvent::start_element(("saml", "Conditions"))
                // TODO: conditions_not_before
                .attr("NotBefore", &self.conditions_not_before.to_rfc3339())
                // TODO: conditions_not_after
                .attr("NotOnOrAfter", &self.conditions_not_after.to_rfc3339())
                .into(),
            writer,
        );

        write_event(
            XmlEvent::start_element(("saml", "AudienceRestriction")).into(),
            writer,
        );
        write_event(XmlEvent::start_element(("saml", "Audience")).into(), writer);
        // TODO: BUG: this is wrong. Assertion contains an unacceptable AudienceRestriction.
        write_event(XmlEvent::characters(&self.audience), writer);
        write_event(XmlEvent::end_element().into(), writer);
        write_event(XmlEvent::end_element().into(), writer);
        // end conditions statement
        write_event(XmlEvent::end_element().into(), writer);
    }
/// adds a `saml:Conditions` statement to the writer
adds a `saml:Conditions` statement to the writer
adds a ` saml : Conditions ` statement to the writer
fn add_conditions<W: Write>(&self, writer: &mut EventWriter<W>) {
        // start conditions statement
        write_event(
            XmlEvent::start_element(("saml", "Conditions"))
                // TODO: conditions_not_before
                .attr("NotBefore", &self.conditions_not_before.to_rfc3339())
                // TODO: conditions_not_after
                .attr("NotOnOrAfter", &self.conditions_not_after.to_rfc3339())
                .into(),
            writer,
        );
        write_event(
            XmlEvent::start_element(("saml", "AudienceRestriction")).into(),
            writer,
        );
        write_event(XmlEvent::start_element(("saml", "Audience")).into(), writer);
        // TODO: BUG: this is wrong. Assertion contains an unacceptable AudienceRestriction.
        write_event(XmlEvent::characters(&self.audience), writer);
        write_event(XmlEvent::end_element().into(), writer);
        write_event(XmlEvent::end_element().into(), writer);
        // end conditions statement
        write_event(XmlEvent::end_element().into(), writer);
    }
fn add_conditions < W : Write > ( & self , writer : & mut EventWriter < W > ) { // start conditions statement write_event ( XmlEvent :: start_element ( ( " " , " " ) ) // TODO: conditions_not_before . attr ( " " , & self . conditions_not_before . to_rfc3339 ( ) ) // TODO: conditions_not_after . attr ( " " , & self . conditions_not_after . to_rfc3339 ( ) ) . into ( ) , writer , ) ; write_event ( XmlEvent :: start_element ( ( " " , " " ) ) . into ( ) , writer , ) ; write_event ( XmlEvent :: start_element ( ( " " , " " ) ) . into ( ) , writer ) ; // TODO: BUG: this is wrong. Assertion contains an unacceptable AudienceRestriction. write_event ( XmlEvent :: characters ( & self . audience ) , writer ) ; write_event ( XmlEvent :: end_element ( ) . into ( ) , writer ) ; write_event ( XmlEvent :: end_element ( ) . into ( ) , writer ) ; // end conditions statement write_event ( XmlEvent :: end_element ( ) . into ( ) , writer ) ; }
adds a `saml:Conditions` statement to the writer
adds a ` saml : Conditions ` statement to the writer
&self
writer
&mut EventWriter<W>
&self
writer
&mut EventWriter<W>