pub struct Workbook { /* private fields */ }Implementations§
Source§impl Workbook
impl Workbook
pub fn get_current_sheet(&self) -> &Sheet
pub fn get_current_sheet_mut(&mut self) -> &mut Sheet
pub fn ensure_sheet_loaded( &mut self, sheet_index: usize, sheet_name: &str, ) -> Result<()>
pub fn get_sheet_by_index(&self, index: usize) -> Option<&Sheet>
pub fn get_sheet_by_name(&self, name: &str) -> Option<&Sheet>
Sourcepub fn resolve_sheet(&self, spec: &str) -> Result<usize>
pub fn resolve_sheet(&self, spec: &str) -> Result<usize>
Resolve a sheet specifier (name or 0-based index) to a sheet index.
Sourcepub fn resolve_sheet_by_name(&self, name: &str) -> Result<usize>
pub fn resolve_sheet_by_name(&self, name: &str) -> Result<usize>
Resolve sheet by exact name.
Sourcepub fn resolve_sheet_by_index(&self, index: usize) -> Result<usize>
pub fn resolve_sheet_by_index(&self, index: usize) -> Result<usize>
Resolve sheet by 0-based index.
Sourcepub fn count_non_empty_rows(&self, sheet_index: usize) -> Result<usize>
pub fn count_non_empty_rows(&self, sheet_index: usize) -> Result<usize>
Compute non-empty row count for a sheet.
Sourcepub fn count_non_empty_cols(&self, sheet_index: usize) -> Result<usize>
pub fn count_non_empty_cols(&self, sheet_index: usize) -> Result<usize>
Compute non-empty column count for a sheet.
Sourcepub fn find_header_candidates(
&self,
sheet_index: usize,
) -> Result<(Vec<usize>, Option<usize>)>
pub fn find_header_candidates( &self, sheet_index: usize, ) -> Result<(Vec<usize>, Option<usize>)>
Find header row candidates for a sheet. Returns (candidates[], recommended_header_row).
Sourcepub fn get_used_range(&self, sheet_index: usize) -> Result<String>
pub fn get_used_range(&self, sheet_index: usize) -> Result<String>
Get the used range of a sheet in A1 notation (e.g., “A1:H2048”). Returns an empty string if the sheet has no data.
pub fn ensure_cell_exists(&mut self, row: usize, col: usize)
pub fn set_cell_value( &mut self, row: usize, col: usize, value: String, ) -> Result<()>
pub fn set_freeze_panes(&mut self, rows: usize, cols: usize)
pub fn clear_freeze_panes(&mut self)
pub fn get_sheet_names(&self) -> Vec<String>
pub fn get_current_sheet_name(&self) -> String
pub fn get_current_sheet_index(&self) -> usize
pub fn switch_sheet(&mut self, index: usize) -> Result<()>
pub fn add_sheet(&mut self, name: &str, index: usize) -> Result<String>
pub fn delete_current_sheet(&mut self) -> Result<()>
pub fn delete_sheet_at_index(&mut self, index: usize) -> Result<()>
pub fn delete_row(&mut self, row: usize) -> Result<()>
pub fn delete_rows(&mut self, start_row: usize, end_row: usize) -> Result<()>
pub fn delete_column(&mut self, col: usize) -> Result<()>
pub fn delete_columns(&mut self, start_col: usize, end_col: usize) -> Result<()>
pub fn is_modified(&self) -> bool
pub fn set_modified(&mut self, modified: bool)
pub fn get_file_path(&self) -> &str
pub fn is_lazy_loading(&self) -> bool
pub fn is_sheet_loaded(&self, sheet_index: usize) -> bool
pub fn insert_sheet_at_index( &mut self, sheet: Sheet, index: usize, ) -> Result<()>
pub fn recalculate_max_cols(&mut self)
pub fn recalculate_max_rows(&mut self)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Workbook
impl RefUnwindSafe for Workbook
impl Send for Workbook
impl Sync for Workbook
impl Unpin for Workbook
impl UnsafeUnpin for Workbook
impl UnwindSafe for Workbook
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more