pub struct CompressionResult {
pub compressed: String,
pub image_data: Option<Vec<u8>>,
pub format: OutputFormat,
pub original_tokens: usize,
pub compressed_tokens: usize,
pub compression_ratio: f32,
pub tokens_removed: usize,
}Expand description
Result of compression operation.
Fields§
§compressed: StringThe compressed text (always included).
image_data: Option<Vec<u8>>Optional image output (PNG bytes).
format: OutputFormatOutput format used.
original_tokens: usizeOriginal token count.
compressed_tokens: usizeCompressed token count.
compression_ratio: f32Compression ratio (compressed/original).
tokens_removed: usizeNumber of tokens removed.
Trait Implementations§
Source§impl Clone for CompressionResult
impl Clone for CompressionResult
Source§fn clone(&self) -> CompressionResult
fn clone(&self) -> CompressionResult
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 moreSource§impl Debug for CompressionResult
impl Debug for CompressionResult
Source§impl<'de> Deserialize<'de> for CompressionResult
impl<'de> Deserialize<'de> for CompressionResult
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for CompressionResult
impl RefUnwindSafe for CompressionResult
impl Send for CompressionResult
impl Sync for CompressionResult
impl Unpin for CompressionResult
impl UnwindSafe for CompressionResult
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