PictureCollection

PictureCollection

Overview

PictureCollection is a class in Aspose.Cells FOSS for Java.

Collection of embedded pictures on a worksheet.

This class provides 7 methods for working with PictureCollection objects in Java. Available methods include: add, contentTypeFromExtension, detectImageType, extensionFromData, get, getCount, removeAt. All public members are accessible to any Java application after installing the Aspose.Cells FOSS for Java package. Properties: count.

Description

PictureCollection is a class in the Aspose.Cells FOSS library for Java that exposes 9 methods and 1 property for programmatic use.

Core capabilities include: Removes the picture at the specified index. These operations enable developers to integrate picturecollection functionality directly into Java applications.

The class also provides the count property (gets the count).

Properties

NameTypeAccessDescription
countintReadGets the count.

Methods

SignatureDescription
getCount()intReturns the count.
get(index: int)PictureReturns the picture at the given index.
add(upperLeftRow: int, upperLeftColumn: int, lowerRightRow: int, lowerRightColumn: int, imageData: byte[])intAdds a picture from raw bytes.
add(upperLeftRow: int, upperLeftColumn: int, lowerRightRow: int, lowerRightColumn: int, stream: InputStream)intAdds a picture from an InputStream.
add(upperLeftRow: int, upperLeftColumn: int, lowerRightRow: int, lowerRightColumn: int, fileName: String)intAdds a picture from a file path.
removeAt(index: int)Removes the picture at the specified index.
detectImageType(data: byte[])ImageTypeDetects and returns the image type from raw byte data.
extensionFromData(data: byte[])StringReturns the file extension inferred from the raw image byte data.
contentTypeFromExtension(ext: String)StringReturns the MIME content type corresponding to the given file extension.

See Also