pub enum MtmdInputPart<'a> {
Text(&'a MtmdInputText<'a>),
Bitmap(&'a MtmdBitmap),
}Expand description
One element of a marker-free prompt, for
MtmdContext::tokenize_from_parts.
Borrows rather than owns, so the caller keeps control of bitmap lifetimes — a bitmap is usually reused across several prompts.
Variants§
Text(&'a MtmdInputText<'a>)
A run of text, with its own parse_special setting.
Bitmap(&'a MtmdBitmap)
An image or audio bitmap spliced in at this position.
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for MtmdInputPart<'a>
impl<'a> RefUnwindSafe for MtmdInputPart<'a>
impl<'a> Send for MtmdInputPart<'a>
impl<'a> Sync for MtmdInputPart<'a>
impl<'a> Unpin for MtmdInputPart<'a>
impl<'a> UnsafeUnpin for MtmdInputPart<'a>
impl<'a> UnwindSafe for MtmdInputPart<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more