Crate simple_endian Copy item path Source encoding_rs (text_utf8 or text_utf16 or text_utf32 or text_fixed) and text_encoding_rs Optional encoding_rs-backed helpers. utf8 (text_utf8 or text_utf16 or text_utf32 or text_fixed) and text_utf8 UTF-8 helpers. BigEndian A big-endian representation of type T that implements SpecificEndian<T>. Data stored in the struct must be converted to big-endian using ::from() or .into(). FixedCodepointStr text_fixedA borrowed view of exactly N Unicode scalar values. FixedCodepointString text_fixedA fixed-length string of exactly N Unicode scalar values (codepoints). FixedUtf8Bytes text_fixed and text_utf8Inline, fixed-size UTF-8 bytes. FixedUtf8BytesRef text_fixed and text_utf8A borrowed reference to exactly N UTF-8 bytes. FixedUtf8NullPadded text_fixed and text_utf8NUL-padded fixed UTF-8 bytes. FixedUtf8SpacePadded text_fixed and text_utf8Space-padded fixed UTF-8 bytes. FixedUtf16BeNullPadded text_fixed and text_utf16Fixed UTF-16BE code units interpreted as a NUL-padded string. FixedUtf16BePacked text_fixed and text_utf16Fixed UTF-16BE code units interpreted as a packed string. FixedUtf16BeSpacePadded text_fixed and text_utf16Fixed UTF-16BE code units interpreted as a space-padded string. FixedUtf16CodeUnitsEndian text_fixed and text_utf16Inline, fixed-size UTF-16 code units stored with explicit endianness. FixedUtf16CodeUnitsRefEndian text_fixed and text_utf16A borrowed reference to exactly N UTF-16 code units stored with explicit endianness. FixedUtf16LeNullPadded text_fixed and text_utf16Fixed UTF-16LE code units interpreted as a NUL-padded string. FixedUtf16LePacked text_fixed and text_utf16Fixed UTF-16LE code units interpreted as a packed string. FixedUtf16LeSpacePadded text_fixed and text_utf16Fixed UTF-16LE code units interpreted as a space-padded string. FixedUtf32BeNullPadded text_fixed and text_utf32Fixed UTF-32BE code units interpreted as a NUL-padded string. FixedUtf32BePacked text_fixed and text_utf32Fixed UTF-32BE code units interpreted as a packed string. FixedUtf32BeSpacePadded text_fixed and text_utf32Fixed UTF-32BE code units interpreted as a space-padded string. FixedUtf32CodeUnitsEndian text_fixed and text_utf32Inline, fixed-size UTF-32 code units stored with explicit endianness. FixedUtf32CodeUnitsRefEndian text_fixed and text_utf32A borrowed reference to exactly N UTF-32 code units stored with explicit endianness. FixedUtf32LeNullPadded text_fixed and text_utf32Fixed UTF-32LE code units interpreted as a NUL-padded string. FixedUtf32LePacked text_fixed and text_utf32Fixed UTF-32LE code units interpreted as a packed string. FixedUtf32LeSpacePadded text_fixed and text_utf32Fixed UTF-32LE code units interpreted as a space-padded string. LittleEndian A little-endian representation of type T that implements SpecificEndian<T>. Data stored in the struct must be converted to little-endian using ::from() or .into(). Utf16StrBE text_utf16Borrowed UTF-16 code units (big-endian encoded u16). Utf16StrLE text_utf16Borrowed UTF-16 code units (little-endian encoded u16). Utf16StringBE text_utf16Owned UTF-16 code units (big-endian u16). Utf16StringLE text_utf16Owned UTF-16 code units (little-endian u16). Utf32StrBE text_utf32Borrowed UTF-32 code units (big-endian encoded u32). Utf32StrLE text_utf32Borrowed UTF-32 code units (little-endian encoded u32). Utf32StringBE text_utf32Owned UTF-32 code units (big-endian u32). Utf32StringLE text_utf32Owned UTF-32 code units (little-endian u32). Endian Any object implementing SpecificEndian<T> can be converted between big and little endian. Implement this trait to allow for endian conversion by this crate. EndianValue io-coreRead raw bytes into a BigEndian<T>. FixedTextError text_fixedError returned when converting into a fixed-codepoint string fails. FixedUtf8Error text_fixed and text_utf8Errors for fixed UTF-8 byte storage. FixedUtf16Error text_fixedErrors for fixed UTF-16 code-unit storage. FixedUtf32Error text_fixed and text_utf32Errors for fixed UTF-32 code-unit storage. Utf16Error text_utf16Errors returned when decoding UTF-16. Utf32Error text_utf32Errors returned when decoding UTF-32. EndianRead io-stdEndianRepr io-coreEndianWrite io-stdFromSlice io-coreTrait describing types that can be read from / written to a byte slice
representation. Implemented for BigEndian<T> and LittleEndian<T>. SimpleEndian A trait for types that do not change based on endianness. SpecificEndian SpecificEndianOwned Endian conversion trait for owned / non-Copy types. from_bytes io-coreRead raw bytes and return an EndianValue<T> chosen by
T::default().endian(). from_bytes_to_native io-coreConvenience: read bytes and return the host-native T directly. read_from_slice io-coreConvenience generic helpers. read_native io-stdRead a value in its wire representation and convert it into a native type. read_specific io-stdRead an endian-aware value of type E from a reader. read_specific_dyn io-stdDyn-friendly adapter for read_specific. try_read_native io-stdLike read_native , but uses TryFrom<W> for fallible conversion. try_write_native io-stdLike write_native , but uses TryFrom<T> for fallible conversion. try_write_native_ref io-stdConvenience wrapper over try_write_native when you only have a reference. write_native io-stdConvert a native value into its wire representation and write it. write_native_ref io-stdConvenience wrapper over write_native when you only have a reference. write_specific io-stdWrite an endian-aware value of type E to a writer. write_specific_dyn io-stdDyn-friendly adapter for write_specific. write_to_extend io-coreFixedUtf16BeCodeUnits text_fixed and text_utf16Big-endian fixed UTF-16 code units. FixedUtf16BeCodeUnitsRef text_fixed and text_utf16A borrowed reference to exactly N UTF-16BE code units. FixedUtf16CodeUnits text_fixed and text_utf16 and little-endianHost-endian fixed UTF-16 code units. FixedUtf16CodeUnitsRef text_fixed and text_utf16 and little-endianA borrowed reference to exactly N host-endian UTF-16 code units. FixedUtf16LeCodeUnits text_fixed and text_utf16Little-endian fixed UTF-16 code units. FixedUtf16LeCodeUnitsRef text_fixed and text_utf16A borrowed reference to exactly N UTF-16LE code units. FixedUtf16LeNullTerminated Deprecated text_fixed and text_utf16Backwards-compatible name for FixedUtf16LeNullPadded . FixedUtf32BeCodeUnits text_fixed and text_utf32FixedUtf32BeCodeUnitsRef text_fixed and text_utf32FixedUtf32CodeUnits text_fixed and text_utf32 and little-endianHost-endian fixed UTF-32 code units. FixedUtf32CodeUnitsRef text_fixed and text_utf32 and little-endianA borrowed reference to exactly N host-endian UTF-32 code units. FixedUtf32LeCodeUnits text_fixed and text_utf32FixedUtf32LeCodeUnitsRef text_fixed and text_utf32Utf16Str text_utf16 and little-endianUtf16String text_utf16 and little-endianUtf32Str text_utf32 and little-endianUtf32String text_utf32 and little-endianf32be Shorthand for BigEndian<f32> f32le Shorthand for LittleEndian<f32> f64be Shorthand for BigEndian<f64> f64le Shorthand for LittleEndian<f64> i16be Shorthand for BigEndian<i16> i16le Shorthand for LittleEndian<i16> i32be Shorthand for BigEndian<i32> i32le Shorthand for LittleEndian<i32> i64be Shorthand for BigEndian<i64> i64le Shorthand for LittleEndian<i64> i128be Shorthand for BigEndian<i128> i128le Shorthand for LittleEndian<i128> isizebe Shorthand for BigEndian<isize> isizele Shorthand for LittleEndian<isize> nzi8be integer_impls and nonzeroShorthand for BigEndian<NonZeroI8> nzi8le integer_impls and nonzeroShorthand for LittleEndian<NonZeroI8> nzi16be integer_impls and nonzeroShorthand for BigEndian<NonZeroI16> nzi16le integer_impls and nonzeroShorthand for LittleEndian<NonZeroI16> nzi32be integer_impls and nonzeroShorthand for BigEndian<NonZeroI32> nzi32le integer_impls and nonzeroShorthand for LittleEndian<NonZeroI32> nzi64be integer_impls and nonzeroShorthand for BigEndian<NonZeroI64> nzi64le integer_impls and nonzeroShorthand for LittleEndian<NonZeroI64> nzi128be integer_impls and nonzeroShorthand for BigEndian<NonZeroI128> nzi128le integer_impls and nonzeroShorthand for LittleEndian<NonZeroI128> nzisizebe integer_impls and nonzeroShorthand for BigEndian<NonZeroIsize> nzisizele integer_impls and nonzeroShorthand for LittleEndian<NonZeroIsize> nzu8be integer_impls and nonzeroShorthand for BigEndian<NonZeroU8> nzu8le integer_impls and nonzeroShorthand for LittleEndian<NonZeroU8> nzu16be integer_impls and nonzeroShorthand for BigEndian<NonZeroU16> nzu16le integer_impls and nonzeroShorthand for LittleEndian<NonZeroU16> nzu32be integer_impls and nonzeroShorthand for BigEndian<NonZeroU32> nzu32le integer_impls and nonzeroShorthand for LittleEndian<NonZeroU32> nzu64be integer_impls and nonzeroShorthand for BigEndian<NonZeroU64> nzu64le integer_impls and nonzeroShorthand for LittleEndian<NonZeroU64> nzu128be integer_impls and nonzeroShorthand for BigEndian<NonZeroU128> nzu128le integer_impls and nonzeroShorthand for LittleEndian<NonZeroU128> nzusizebe integer_impls and nonzeroShorthand for BigEndian<NonZeroUsize> nzusizele integer_impls and nonzeroShorthand for LittleEndian<NonZeroUsize> u16be Shorthand for BigEndian<u16> u16le Shorthand for LittleEndian<u16> u32be Shorthand for BigEndian<u32> u32le Shorthand for LittleEndian<u32> u64be Shorthand for BigEndian<u64> u64le Shorthand for LittleEndian<u64> u128be Shorthand for BigEndian<u128> u128le Shorthand for LittleEndian<u128> usizebe Shorthand for BigEndian<usize> usizele Shorthand for LittleEndian<usize> Endianize deriveGenerate a “wire-format” struct and endian wrapper aliases.