PictureCollection

PictureCollection

Overview

PictureCollection is a struct in Aspose.Cells FOSS for Rust.

Represents collection of pictures anchored to a worksheet.

This struct provides 10 methods for working with PictureCollection objects in Rust programs. Available methods include: add, add_from_bytes, add_from_file, add_from_reader, clear, count, get, get_count, item, remove_at. All public members are accessible to any Rust application after installing the Aspose.Cells FOSS for Rust package.

Methods

SignatureDescription
count()usizeGets the number of items.
get_count()usizeGets the number of items.
add(upper_left_row: i32, upper_left_column: i32, lower_right_row: i32, lower_right_column: i32, image_data: Vec<u8>)Result<usize, CellsError>Adds a picture to the worksheet from a file path and returns its index.
add_from_bytes(upper_left_row: i32, upper_left_column: i32, lower_right_row: i32, lower_right_column: i32, image_data: &[u8])Result<usize, CellsError>Adds an item.
add_from_reader(upper_left_row: i32, upper_left_column: i32, lower_right_row: i32, lower_right_column: i32, reader: R)Result<usize, CellsError>Adds a picture from a reader and returns its zero-based index.
add_from_file(upper_left_row: i32, upper_left_column: i32, lower_right_row: i32, lower_right_column: i32, path: impl AsRef<Path>)Result<usize, CellsError>Adds an item.
get(index: usize)Option<Picture<'_>>Gets the item from the collection.
item(index: usize)Option<Picture<'_>>Gets the item from the collection.
remove_at(index: usize)Result<(), CellsError>Removes an item.
clear()Clears the current state.

See Also