pub struct TokenChunk {
pub text: String,
pub pos: usize,
pub tokens: usize,
pub bytes: usize,
}Expand description
A document chunk with token information.
Fields§
§text: StringThe text content of the chunk
pos: usizeCharacter position in original document
tokens: usizeToken count for this chunk
bytes: usizeByte size of the chunk
Trait Implementations§
Source§impl Clone for TokenChunk
impl Clone for TokenChunk
Source§fn clone(&self) -> TokenChunk
fn clone(&self) -> TokenChunk
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for TokenChunk
impl RefUnwindSafe for TokenChunk
impl Send for TokenChunk
impl Sync for TokenChunk
impl Unpin for TokenChunk
impl UnwindSafe for TokenChunk
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