Trait allsorts_no_std::binary::write::WriteBinary [−][src]
Trait that describes a type that can be written to a WriteContext
in binary form.
Associated Types
Loading content...Required methods
fn write<C: WriteContext>(
ctxt: &mut C,
val: HostType
) -> Result<Self::Output, WriteError>
[src]
ctxt: &mut C,
val: HostType
) -> Result<Self::Output, WriteError>
Write the binary representation of Self to ctxt
.
Implementors
impl WriteBinary<&'_ Operand> for Operand
[src]
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, op: &Operand) -> Result<(), WriteError>
[src]
impl WriteBinary<&'_ Header> for allsorts_no_std::cff::Header
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
header: &Header
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
header: &Header
) -> Result<(), WriteError>
impl WriteBinary<&'_ TableRecord> for TableRecord
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
table: &TableRecord
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
table: &TableRecord
) -> Result<(), WriteError>
impl WriteBinary<Operator> for Operator
[src]
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, op: Operator) -> Result<(), WriteError>
[src]
impl WriteBinary<IndexToLocFormat> for IndexToLocFormat
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
index_to_loc_format: Self
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
index_to_loc_format: Self
) -> Result<(), WriteError>
impl WriteBinary<SequentialMapGroup> for SequentialMapGroup
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
group: SequentialMapGroup
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
group: SequentialMapGroup
) -> Result<(), WriteError>
impl WriteBinary<F2Dot14> for F2Dot14
[src]
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, val: Self) -> Result<(), WriteError>
[src]
impl<'a> WriteBinary<&'_ CustomCharset<'a>> for CustomCharset<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
charset: &Self
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
charset: &Self
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ CustomEncoding<'a>> for CustomEncoding<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
encoding: &Self
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
encoding: &Self
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ FDSelect<'a>> for FDSelect<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
fd_select: &Self
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
fd_select: &Self
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ MaybeOwnedIndex<'a>> for MaybeOwnedIndex<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
index: &MaybeOwnedIndex<'a>
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
index: &MaybeOwnedIndex<'a>
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ CmapSubtable<'a>> for allsorts_no_std::tables::cmap::CmapSubtable<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
table: &CmapSubtable<'a>
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
table: &CmapSubtable<'a>
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ CFF<'a>> for CFF<'a>
[src]
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, cff: &CFF<'a>) -> Result<(), WriteError>
[src]
impl<'a> WriteBinary<&'_ CIDData<'a>> for CIDData<'a>
[src]
type Output = CIDDataOffsets
fn write<C: WriteContext>(
ctxt: &mut C,
data: &Self
) -> Result<Self::Output, WriteError>
[src]
ctxt: &mut C,
data: &Self
) -> Result<Self::Output, WriteError>
impl<'a> WriteBinary<&'_ Index<'a>> for Index<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
index: &Index<'a>
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
index: &Index<'a>
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ Type1Data<'a>> for Type1Data<'a>
[src]
type Output = Type1DataOffsets
fn write<C: WriteContext>(
ctxt: &mut C,
data: &Self
) -> Result<Self::Output, WriteError>
[src]
ctxt: &mut C,
data: &Self
) -> Result<Self::Output, WriteError>
impl<'a> WriteBinary<&'_ Header> for allsorts_no_std::post::Header
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
table: &Header
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
table: &Header
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ PascalString<'a>> for PascalString<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
string: &PascalString<'a>
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
string: &PascalString<'a>
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ PostTable<'a>> for PostTable<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
table: &PostTable<'a>
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
table: &PostTable<'a>
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ SubTable<'a>> for SubTable<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
table: &SubTable<'a>
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
table: &SubTable<'a>
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ HeadTable> for HeadTable
[src]
type Output = Placeholder<U32Be, u32>
fn write<C: WriteContext>(
ctxt: &mut C,
table: &HeadTable
) -> Result<Self::Output, WriteError>
[src]
ctxt: &mut C,
table: &HeadTable
) -> Result<Self::Output, WriteError>
Writes the table to the WriteContext
and returns a placeholder to the check_sum_adjustment
field.
The check_sum_adjustment
field requires special handling to calculate. See:
https://docs.microsoft.com/en-us/typography/opentype/spec/head
impl<'a> WriteBinary<&'_ HheaTable> for HheaTable
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
table: &HheaTable
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
table: &HheaTable
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ HmtxTable<'a>> for HmtxTable<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
table: &HmtxTable<'a>
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
table: &HmtxTable<'a>
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ MaxpTable> for MaxpTable
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
table: &MaxpTable
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
table: &MaxpTable
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ MaxpVersion1SubTable> for MaxpVersion1SubTable
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
table: &MaxpVersion1SubTable
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
table: &MaxpVersion1SubTable
) -> Result<(), WriteError>
impl<'a> WriteBinary<&'_ NameTable<'a>> for NameTable<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
name: &NameTable<'a>
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
name: &NameTable<'a>
) -> Result<(), WriteError>
impl<'a> WriteBinary<CmapSubtable> for allsorts_no_std::tables::cmap::owned::CmapSubtable
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
table: CmapSubtable
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
table: CmapSubtable
) -> Result<(), WriteError>
impl<'a> WriteBinary<CompositeGlyphArgument> for CompositeGlyphArgument
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
arg: CompositeGlyphArgument
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
arg: CompositeGlyphArgument
) -> Result<(), WriteError>
impl<'a> WriteBinary<CompositeGlyphScale> for CompositeGlyphScale
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
scale: CompositeGlyphScale
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
scale: CompositeGlyphScale
) -> Result<(), WriteError>
impl<'a> WriteBinary<ReadScope<'a>> for ReadScope<'a>
[src]
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, scope: Self) -> Result<(), WriteError>
[src]
impl<'a> WriteBinary<Range<u8, u8>> for Range<u8, u8>
[src]
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, range: Self) -> Result<(), WriteError>
[src]
impl<'a> WriteBinary<Range<u16, u8>> for Range<u16, u8>
[src]
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, range: Self) -> Result<(), WriteError>
[src]
impl<'a> WriteBinary<Range<u16, u16>> for Range<u16, u16>
[src]
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, range: Self) -> Result<(), WriteError>
[src]
impl<'a> WriteBinary<Cmap> for Cmap
[src]
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, table: Cmap) -> Result<(), WriteError>
[src]
impl<'a> WriteBinary<BoundingBox> for BoundingBox
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
bbox: BoundingBox
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
bbox: BoundingBox
) -> Result<(), WriteError>
impl<'a> WriteBinary<CompositeGlyph> for CompositeGlyph
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
glyph: CompositeGlyph
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
glyph: CompositeGlyph
) -> Result<(), WriteError>
impl<'a> WriteBinary<Glyph<'a>> for Glyph<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
glyph: Glyph<'a>
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
glyph: Glyph<'a>
) -> Result<(), WriteError>
impl<'a> WriteBinary<SimpleGlyph> for SimpleGlyph
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
glyph: SimpleGlyph
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
glyph: SimpleGlyph
) -> Result<(), WriteError>
impl<'a> WriteBinary<LocaTable<'a>> for LocaTable<'a>
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
loca: LocaTable<'a>
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
loca: LocaTable<'a>
) -> Result<(), WriteError>
impl<'a> WriteBinary<LangTagRecord> for LangTagRecord
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
record: LangTagRecord
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
record: LangTagRecord
) -> Result<(), WriteError>
impl<'a> WriteBinary<LongHorMetric> for LongHorMetric
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
metric: LongHorMetric
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
metric: LongHorMetric
) -> Result<(), WriteError>
impl<'a> WriteBinary<NameRecord> for NameRecord
[src]
type Output = ()
fn write<C: WriteContext>(
ctxt: &mut C,
record: NameRecord
) -> Result<(), WriteError>
[src]
ctxt: &mut C,
record: NameRecord
) -> Result<(), WriteError>
impl<'a, T> WriteBinary<&'_ ReadArrayCow<'a, T>> for ReadArrayCow<'a, T> where
T: ReadUnchecked<'a> + WriteBinary<<T as ReadUnchecked<'a>>::HostType>,
T::HostType: Copy,
[src]
T: ReadUnchecked<'a> + WriteBinary<<T as ReadUnchecked<'a>>::HostType>,
T::HostType: Copy,
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, array: &Self) -> Result<(), WriteError>
[src]
impl<'a, T> WriteBinary<&'_ ReadArray<'a, T>> for &ReadArray<'a, T> where
T: ReadUnchecked<'a> + WriteBinary<<T as ReadUnchecked<'a>>::HostType>,
[src]
T: ReadUnchecked<'a> + WriteBinary<<T as ReadUnchecked<'a>>::HostType>,
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, array: Self) -> Result<(), WriteError>
[src]
impl<T> WriteBinary<T> for I8 where
T: Into<i8>,
[src]
T: Into<i8>,
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, t: T) -> Result<(), WriteError>
[src]
impl<T> WriteBinary<T> for I16Be where
T: Into<i16>,
[src]
T: Into<i16>,
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, t: T) -> Result<(), WriteError>
[src]
impl<T> WriteBinary<T> for I32Be where
T: Into<i32>,
[src]
T: Into<i32>,
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, t: T) -> Result<(), WriteError>
[src]
impl<T> WriteBinary<T> for I64Be where
T: Into<i64>,
[src]
T: Into<i64>,
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, t: T) -> Result<(), WriteError>
[src]
impl<T> WriteBinary<T> for U8 where
T: Into<u8>,
[src]
T: Into<u8>,
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, t: T) -> Result<(), WriteError>
[src]
impl<T> WriteBinary<T> for U16Be where
T: Into<u16>,
[src]
T: Into<u16>,
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, t: T) -> Result<(), WriteError>
[src]
impl<T> WriteBinary<T> for U24Be where
T: Into<u32>,
[src]
T: Into<u32>,
type Output = ()
fn write<C: WriteContext>(ctxt: &mut C, t: T) -> Result<(), WriteError>
[src]
impl<T> WriteBinary<T> for U32Be where
T: Into<u32>,
[src]
T: Into<u32>,