WorksheetsMut
概述
WorksheetsMut 是 Aspose.Cells Rust 开源软件中的结构体。
封装工作簿的工作表以及活动工作表的状态。
此结构体在 Rust 程序中为 WorksheetsMut 对象声明了 19 个方法。可用的方法包括:active_sheet_index、active_sheet_name、add、add_default、count、get、get_active_sheet_index、get_active_sheet_name、get_by_name、get_count、get_ref、is_empty,以及另外 7 个方法。安装 Aspose.Cells Rust 开源软件包后,公共成员对任何 Rust 应用程序均可访问。
方法
| 签名 | 描述 |
|---|---|
add(name: impl Into<String>) → Result<usize, CellsError> | 添加一个具有指定名称的工作表,并返回其索引。 |
add_default() → Result<usize, CellsError> | 添加一个项目。 |
count() → usize | 获取项目的数量。 |
get_count() → usize | 获取项目的数量。 |
get(index: usize) → Result<&mut Worksheet, CellsError> | 获取集合中的项。 |
item(index: usize) → Result<&mut Worksheet, CellsError> | 从集合中获取该项。 |
get_by_name(name: &str) → Result<&mut Worksheet, CellsError> | 获取关联的值。 |
item_by_name(name: &str) → Result<&mut Worksheet, CellsError> | 获取集合中的项。 |
get_ref(index: usize) → Result<&Worksheet, CellsError> | 按索引的只读访问器;仅在需要共享访问时很有用。 |
active_sheet_index() → usize | 获取活动工作表的零基索引。 |
get_active_sheet_index() → usize | 获取活动工作表的零基索引。 |
set_active_sheet_index(value: usize) → Result<(), CellsError> | 设置活动工作表的零基索引。 |
active_sheet_name() → String | 获取活动工作表的名称。 |
get_active_sheet_name() → String | 获取活动工作表的名称。 |
set_active_sheet_name(value: &str) → Result<(), CellsError> | 设置活动工作表的名称。 |
remove_at(index: usize) → Result<(), CellsError> | 删除一个项目。 |
remove_at_name(name: &str) → Result<(), CellsError> | 删除一个项目。 |
len() → usize | 获取集合中的项数。 |
is_empty() → bool | 返回集合是否为空。 |