Smee.Publish (Smee v0.1.0) View Source

Publish exports streams or lists of entity structs into various formats.

At present the output formats are SAML XML (individual and collections) and simple index text files. Formats can be output as binary strings or streamed. Streamed output can be useful for web services, allowing gradual downloads generated on-the-fly with no need to render a very large document in advance.

Link to this section Summary

Functions

Returns an index text document

Returns a streamed index file, a plain text list of entity IDs.

Returns the estimated size of a streamed index file without generating it in advance.

Returns a SAML metadata XML file, potentially very large.

Returns a streamed SAML metadata XML file

Returns the estimated size of a streamed SAML metadata XML file without generating it in advance.

Link to this section Functions

Link to this function

aggregate_footer(options)

View Source

Specs

aggregate_footer(options :: keyword()) :: binary()
Link to this function

aggregate_header(options \\ [])

View Source

Specs

aggregate_header(options :: keyword()) :: binary()
Link to this function

to_index(entities, options \\ [])

View Source

Specs

to_index(entities :: Enumerable.t(), options :: keyword()) :: binary()

Returns an index text document

Link to this function

to_index_stream(entities, options \\ [])

View Source

Specs

to_index_stream(entities :: Enumerable.t(), options :: keyword()) ::
  Enumerable.t()

Returns a streamed index file, a plain text list of entity IDs.

Link to this function

to_index_stream_size(entities, options \\ [])

View Source

Specs

to_index_stream_size(entities :: Enumerable.t(), options :: keyword()) ::
  integer()

Returns the estimated size of a streamed index file without generating it in advance.

Link to this function

to_xml(entities, options \\ [])

View Source

Specs

to_xml(entities :: Enumerable.t(), options :: keyword()) :: binary()

Returns a SAML metadata XML file, potentially very large.

Link to this function

to_xml_stream(entity, options \\ [])

View Source

Specs

to_xml_stream(
  entities :: Smee.Entity.t() | Enumerable.t(),
  options :: keyword()
) ::
  Enumerable.t()

Returns a streamed SAML metadata XML file

Link to this function

to_xml_stream_size(entities, options \\ [])

View Source

Specs

to_xml_stream_size(entities :: Enumerable.t(), options :: keyword()) ::
  integer()

Returns the estimated size of a streamed SAML metadata XML file without generating it in advance.