Package-level declarations

Types

Link copied to clipboard
open class AbstractXmlNamespaceTrait(val uri: String, val prefix: String? = null)

Base class for more specific XML namespace traits

Link copied to clipboard
object Flattened

Denotes a collection type that uses a flattened XML representation see: xmlflattened trait

Link copied to clipboard
data class XmlAliasName(val name: String)

Specifies an alternate name that can be used to match an XML node.

Link copied to clipboard

Specifies that a field is encoded into an XML attribute and describes the XML. See https://awslabs.github.io/smithy/spec/xml.html#xmlattribute-trait

Link copied to clipboard
data class XmlCollectionName(val element: String)

Specifies element wrapper name used to encode a List structure. See https://awslabs.github.io/smithy/spec/xml.html#list-and-set-serialization

Link copied to clipboard

Describes the namespace of a list or map's value element Applies to SerialKind.List or SerialKind.Map

Link copied to clipboard
object XmlError

Denotes a structure that represents an error. There are special rules for error deserialization in various XML-based protocols. This trait provides necessary context to the deserializer to properly deserialize error response data into types.

Link copied to clipboard
class XmlMapKeyNamespace(val uri: String, val prefix: String? = null) : AbstractXmlNamespaceTrait

Describes the namespace associated with a map's key element Applies to SerialKind.Map

Link copied to clipboard
data class XmlMapName(val entry: String? = Default.entry, val key: String = Default.key, val value: String = Default.value)

Specifies entry, key, and value node names used to encode a Map structure. See https://awslabs.github.io/smithy/spec/xml.html#map-serialization

Link copied to clipboard
class XmlNamespace(val uri: String, val prefix: String? = null) : AbstractXmlNamespaceTrait

Describes the namespace associated with a field. See https://awslabs.github.io/smithy/spec/xml.html#xmlnamespace-trait

Link copied to clipboard
class XmlSerializer(xmlWriter: XmlStreamWriter = xmlStreamWriter())

Provides serialization for the XML message format.

Link copied to clipboard
data class XmlSerialName(val name: String)

Specifies the name that a field is encoded into for Xml nodes. See https://awslabs.github.io/smithy/1.0/spec/core/xml-traits.html?highlight=xmlname#xmlname-trait

Link copied to clipboard
interface XmlStreamReader

Provides stream-style access to an XML payload. This abstraction supports the ability to look ahead an arbitrary number of elements. It can also create "views" to subtrees of the document, guaranteeing that clients do not exceed bounds.

Link copied to clipboard
interface XmlStreamWriter

Defines an interface to serialization of an XML Infoset.

Link copied to clipboard

An XmlStreamReader scoped to reading a single XML element tag XmlTagReader provides a "tag" scoped view into an XML document. Methods return null when the current tag has been exhausted.

Link copied to clipboard
sealed class XmlToken

Raw tokens produced when reading an XML document as a stream

Link copied to clipboard

Specifies that an object is XML unwrapped response.

Functions

Link copied to clipboard

Creates an XmlStreamReader instance

Link copied to clipboard
Link copied to clipboard

Get a XmlTagReader for the root tag. This is the entry point for beginning deserialization.

Inherited functions

Link copied to clipboard

Unwrap the next token as XmlToken.Text and return its value or throw a DeserializationException

Link copied to clipboard
inline fun <T : XmlToken> XmlStreamReader.peekSeek(selectionPredicate: (T) -> Boolean = { true }): T?

Peek and seek forward until a token of type T is found. If it matches the selectionPredicate, consume the token and return it. Otherwise, return null without consuming the token.

Link copied to clipboard
inline fun <T : XmlToken> XmlStreamReader.seek(selectionPredicate: (T) -> Boolean = { true }): T?

Seek from the current token onward to find a token of specified type and predication.

Link copied to clipboard

Create a new reader scoped to this element.

Link copied to clipboard
Link copied to clipboard
fun XmlTagReader.tryData(): <Error class: unknown class><String>

Attempt to get the text token as XmlToken.Text and return a result containing its' value on success or the exception thrown on failure.