pub struct OptimizationResult {
pub optimized_script: ScriptBuf,
pub original_size: usize,
pub optimized_size: usize,
pub bytes_saved: usize,
pub reduction_percentage: f64,
pub optimizations_applied: Vec<OptimizationType>,
pub is_safe: bool,
pub warnings: Vec<String>,
}Expand description
Result of script optimization
Fields§
§optimized_script: ScriptBufThe optimized script
original_size: usizeOriginal script size in bytes
optimized_size: usizeOptimized script size in bytes
bytes_saved: usizeNumber of bytes saved
reduction_percentage: f64Percentage reduction
optimizations_applied: Vec<OptimizationType>List of optimizations applied
is_safe: boolWhether the script is safe to use (semantics preserved)
warnings: Vec<String>Warnings about potential issues
Trait Implementations§
Source§impl Clone for OptimizationResult
impl Clone for OptimizationResult
Source§fn clone(&self) -> OptimizationResult
fn clone(&self) -> OptimizationResult
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 OptimizationResult
impl Debug for OptimizationResult
Source§impl<'de> Deserialize<'de> for OptimizationResult
impl<'de> Deserialize<'de> for OptimizationResult
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 OptimizationResult
impl RefUnwindSafe for OptimizationResult
impl Send for OptimizationResult
impl Sync for OptimizationResult
impl Unpin for OptimizationResult
impl UnwindSafe for OptimizationResult
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