Skip to main content

Crate anyxml_encoding

Crate anyxml_encoding 

Source
Expand description

Provide a unified interface for encoders and decoders, and a default implementation for some encodings.

If it is necessary to provide a custom decoder for XML processor, a type implementing the Decoder trait can be registered using the register_decoder function.

By default, the encoding name provided to the register_encoder or register_decoder function is used to search for encoders and decoders.
If it is necessary to assign multiple names to a single encoder or decoder, it is possible to set aliases for encoding names using register_encoding_alias.

The default encoding names and aliases are based on IANA registrations.

Structs§

IBM037Decoder
IBM037Encoder
IBM273Decoder
IBM273Encoder
IBM274Decoder
IBM274Encoder
IBM275Decoder
IBM275Encoder
IBM277Decoder
IBM277Encoder
IBM278Decoder
IBM278Encoder
IBM280Decoder
IBM280Encoder
IBM284Decoder
IBM284Encoder
IBM285Decoder
IBM285Encoder
IBM290Decoder
IBM290Encoder
IBM297Decoder
IBM297Encoder
IBM420Decoder
IBM420Encoder
IBM423Decoder
IBM423Encoder
IBM424Decoder
IBM424Encoder
IBM437Decoder
IBM437Encoder
IBM500Decoder
IBM500Encoder
IBM850Decoder
IBM850Encoder
IBM851Decoder
IBM851Encoder
IBM852Decoder
IBM852Encoder
IBM855Decoder
IBM855Encoder
IBM857Decoder
IBM857Encoder
IBM860Decoder
IBM860Encoder
IBM861Decoder
IBM861Encoder
IBM862Decoder
IBM862Encoder
IBM863Decoder
IBM863Encoder
IBM864Decoder
IBM864Encoder
IBM865Decoder
IBM865Encoder
IBM868Decoder
IBM868Encoder
IBM869Decoder
IBM869Encoder
IBM870Decoder
IBM870Encoder
IBM871Decoder
IBM871Encoder
IBM880Decoder
IBM880Encoder
IBM891Decoder
IBM891Encoder
IBM903Decoder
IBM903Encoder
IBM904Decoder
IBM904Encoder
IBM905Decoder
IBM905Encoder
IBM918Decoder
IBM918Encoder
IBM1026Decoder
IBM1026Encoder
ISO8859_1Decoder
ISO8859_1Encoder
ISO8859_2Decoder
ISO8859_2Encoder
ISO8859_3Decoder
ISO8859_3Encoder
ISO8859_4Decoder
ISO8859_4Encoder
ISO8859_5Decoder
ISO8859_5Encoder
ISO8859_6Decoder
ISO8859_6Encoder
ISO8859_7Decoder
ISO8859_7Encoder
ISO8859_8Decoder
ISO8859_8Encoder
ISO8859_9Decoder
ISO8859_9Encoder
ISO8859_10Decoder
ISO8859_10Encoder
ISO8859_11Decoder
ISO8859_11Encoder
ISO8859_13Decoder
ISO8859_13Encoder
ISO8859_14Decoder
ISO8859_14Encoder
ISO8859_15Decoder
ISO8859_15Encoder
ISO8859_16Decoder
ISO8859_16Encoder
ShiftJISDecoder
ShiftJISEncoder
UCS4Unusual2143Decoder
UCS4Unusual2143Encoder
UCS4Unusual3412Decoder
UCS4Unusual3412Encoder
USASCIIDecoder
USASCIIEncoder
UTF8Decoder
UTF8Encoder
UTF16BEDecoder
UTF16BEEncoder
UTF16Decoder
UTF16Encoder
UTF16LEDecoder
UTF16LEEncoder
UTF32BEDecoder
UTF32BEEncoder
UTF32Decoder
UTF32Encoder
UTF32LEDecoder
UTF32LEEncoder

Enums§

DecodeError
EncodeError

Constants§

DEFAULT_SUPPORTED_ENCODINGS
Supported encodings.
IBM037
IBM273
IBM274
IBM275
IBM277
IBM278
IBM280
IBM284
IBM285
IBM290
IBM297
IBM420
IBM423
IBM424
IBM437
IBM500
IBM850
IBM851
IBM852
IBM855
IBM857
IBM860
IBM861
IBM862
IBM863
IBM864
IBM865
IBM868
IBM869
IBM870
IBM871
IBM880
IBM891
IBM903
IBM904
IBM905
IBM918
IBM1026
ISO_8859_1_NAME
ISO_8859_2_NAME
ISO_8859_3_NAME
ISO_8859_4_NAME
ISO_8859_5_NAME
ISO_8859_6_NAME
ISO_8859_7_NAME
ISO_8859_8_NAME
ISO_8859_9_NAME
ISO_8859_10_NAME
ISO_8859_11_NAME
ISO_8859_13_NAME
ISO_8859_14_NAME
ISO_8859_15_NAME
ISO_8859_16_NAME
SHIFT_JIS_NAME
US_ASCII_NAME
UTF8_NAME
UTF16BE_NAME
UTF16LE_NAME
UTF16_NAME
UTF32BE_NAME
UTF32LE_NAME
UTF32_NAME

Statics§

DECODER_TABLE
ENCODER_TABLE
ENCODING_ALIASES
Manage aliases for encoding names.

Traits§

Decoder
Encoder

Functions§

find_decoder
find_encoder
register_decoder
register_encoder
register_encoding_alias
Register alias as an alias for the encoding name real.
If alias is already an alias for another encoding name, overwrite it and return the encoding name before the overwrite.
resolve_encoding_alias
Retrieve the encoding name from alias, which is an alias for a certain encoding name.
If retrieval fails, returns None.
unregister_decoder
unregister_encoder
unregister_encoding_alias
Unregister alias if it is registerd as an alias for an encoding name.
If successfully removed, return the real name.

Type Aliases§

DecoderFactory
EncoderFactory