PDF4Java Reference Documentation
com.o2sol.pdf4java.core.cos Package / PDFCosArray Class / getAsCosContainer Method
Index of element to return.
default value to return if the element at the specified index is not a COS dictionary container
Collapse All Expand All
In This Topic

getAsCosContainer Method
In This Topic
Gets the element at the specified index as a COS dictionary container.
Syntax

    public PDFCosDictionaryContainer getAsCosContainer(
       int index,
       PDFCosDictionaryContainer defaultValue
    )

#### Parameters

index
  Index of element to return.
defaultValue
  default value to return if the element at the specified index is not a COS dictionary container

#### Return Value

The element at the specified index.
Exceptions

Exception | Description
--- | ---
java.lang.IllegalArgumentException | Thrown when the index value is invalid

See Also

#### Reference

PDFCosArray Class
PDFCosArray Members

© 2025 O2 Solutions All Rights Reserved.

Send comments on this topic.