Render a stream of Events into a stream of Builders. Builders are from the blaze-builder package, and allow the create of optimally sized ByteStrings with minimal buffer copying.
Modulexml-conduit-1.10.0.0Haskell2010
Text.XML.Stream.Render
Enumeratees to render XML Events. Unlike libxml-enumerator and
expat-enumerator, this module does not provide IO and ST variants, since the
underlying rendering operations are pure functions.
- 2 types
- 13 values
- Packagexml-conduit-1.10.0.0
- Exports16
- LanguageHaskell2010
- LicenceMIT
- SourceRender.hs
Rendering XML files
4 declarationsSame as renderBuilder but allows you to flush XML stream to ensure that all events at needed point are rendered.
Render a stream of Events into a stream of ByteStrings. This function wraps around renderBuilder and builderToByteString, so it produces optimally sized ByteStrings with minimal buffer copying.
The output is UTF8 encoded.
Render a stream of Events into a stream of Texts. This function wraps around renderBuilder, builderToByteString and renderBytes, so it produces optimally sized Texts with minimal buffer copying.
Renderer settings
7 declarationsInstances1Default
Default RenderSettingsDefined in xml-conduit-1.10.0.0 · Text.XML.Stream.Render.Internal
The default value for this type.
Defines some top level namespace definitions to be used, in the form of (prefix, namespace). This has absolutely no impact on the meaning of your documents, but can increase readability by moving commonly used namespace declarations to the top level.
Specify how to turn the unordered attributes used by the Text.XML module into an ordered list.
Determines if for a given text content the renderer should use a CDATA node.
Default: False
Determines whether the XML declaration will be output.
Default: True
Convenience function to create an ordering function suitable for use as the value of rsAttrOrder. The ordering function is created from an explicit ordering of the attributes, specified as a list of tuples, as follows: In each tuple, the first component is the Name of an element, and the second component is a list of attributes names. When the given element is rendered, the attributes listed, when present, appear first in the given order, followed by any other attributes in arbitrary order. If an element does not appear, all of its attributes are rendered in arbitrary order.
Event rendering
2 declarationstag Generate a complete XML Element.
Generate a textual EventContent.
Attribute rendering
3 declarationsA list of attributes.
Instances2Semigroup, Monoid
Semigroup AttributesDefined in xml-conduit-1.10.0.0 · Text.XML.Stream.Render.InternalMonoid AttributesDefined in xml-conduit-1.10.0.0 · Text.XML.Stream.Render.Internal
Generate a single attribute.