Trait tiff_encoder::tiff_type::TiffType [−][src]
pub trait TiffType {
fn id() -> u16;
fn size() -> u32;
fn write_to(self, file: &mut EndianFile) -> Result<()>;
}A type of data for TIFF fields.
Other types that might come to exist (and aren't supported by this crate yet) can be easily implemented by implementing this trait.
Required Methods
fn id() -> u16
The TIFF 16-bit code that identifies the type.
fn size() -> u32
The number of bytes occupied by a single value of this type.
fn write_to(self, file: &mut EndianFile) -> Result<()>
The function that writes this type to a given EndianFile.
Panics
Will panic if the number of bytes written to the file is
different than the number of bytes specified in size().
Implementors
impl TiffType for BYTEimpl TiffType for ASCIIimpl TiffType for SHORTimpl TiffType for LONGimpl TiffType for RATIONALimpl TiffType for SBYTEimpl TiffType for UNDEFINEDimpl TiffType for SSHORTimpl TiffType for SLONGimpl TiffType for SRATIONALimpl TiffType for FLOATimpl TiffType for DOUBLEimpl TiffType for IFD