Struct edit_xlsx::Workbook

source ·
pub struct Workbook {
    pub sheets: Vec<WorkSheet>,
    /* private fields */
}

Fields§

§sheets: Vec<WorkSheet>

Implementations§

source§

impl Workbook

source

pub fn new() -> Workbook

source

pub fn get_worksheet_mut(&mut self, id: u32) -> WorkbookResult<&mut WorkSheet>

source

pub fn get_worksheet(&self, id: u32) -> WorkbookResult<&WorkSheet>

source

pub fn get_worksheet_by_name(&self, name: &str) -> WorkbookResult<&WorkSheet>

source

pub fn get_worksheet_mut_by_name( &mut self, name: &str ) -> WorkbookResult<&mut WorkSheet>

source

pub fn add_worksheet(&mut self) -> WorkbookResult<&mut WorkSheet>

source

pub fn add_worksheet_by_name( &mut self, name: &str ) -> WorkbookResult<&mut WorkSheet>

source

pub fn duplicate_worksheet(&mut self, id: u32) -> WorkbookResult<&mut WorkSheet>

source

pub fn duplicate_worksheet_by_name( &mut self, name: &str ) -> WorkbookResult<&mut WorkSheet>

source

pub fn set_size(&mut self, width: u32, height: u32) -> WorkbookResult<()>

source

pub fn set_tab_ratio(&mut self, tab_ratio: f64) -> WorkbookResult<()>

source

pub fn define_name(&mut self, name: &str, value: &str) -> WorkbookResult<()>

source

pub fn define_local_name( &mut self, name: &str, value: &str, sheet_id: u32 ) -> WorkbookResult<()>

source

pub fn worksheets_mut(&mut self) -> IterMut<'_, WorkSheet>

source

pub fn worksheets(&self) -> Iter<'_, WorkSheet>

source

pub fn set_properties( &mut self, properties: &Properties<'_> ) -> WorkbookResult<()>

source§

impl Workbook

source

pub fn from_path<P: AsRef<Path>>(file_path: P) -> WorkbookResult<Workbook>

source

pub fn save_as<P: AsRef<Path>>(&self, file_path: P) -> WorkbookResult<()>

source

pub fn save(&mut self) -> WorkbookResult<()>

source

pub fn finish(&mut self)

Trait Implementations§

source§

impl Debug for Workbook

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Drop for Workbook

source§

fn drop(&mut self)

Executes the destructor for this type. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.