CosPdfDictionary
Inheritance: java.lang.Object, com.aspose.pdf.dataeditor.CosPdfPrimitive com.aspose.pdf.dataeditor.CosPdfDictionary, com.aspose.pdf.dataeditor.CosPdfPrimitive, com.aspose.pdf.dataeditor.CosPdfDictionary
All Implemented Interfaces: com.aspose.ms.System.Collections.Generic.IGenericCollection<com.aspose.ms.System.Collections.Generic.KeyValuePair< String, ICosPdfPrimitive », com.aspose.ms.System.Collections.Generic.IGenericDictionary< String, ICosPdfPrimitive >, com.aspose.ms.System.Collections.Generic.IGenericEnumerable<com.aspose.ms.System.Collections.Generic.KeyValuePair< String, ICosPdfPrimitive », com.aspose.ms.System.Collections.IEnumerable<com.aspose.ms.System.Collections.Generic.KeyValuePair< String, ICosPdfPrimitive », ICosPdfPrimitive, Iterable <com.aspose.ms.System.Collections.Generic.KeyValuePair< String, ICosPdfPrimitive »
public class CosPdfDictionary extends CosPdfPrimitive implements com.aspose.ms.System.Collections.Generic.IGenericDictionary< String , ICosPdfPrimitive >
A class for accessing an object’s dictionary.
Constructors
| Constructor | Description |
|---|---|
| CosPdfDictionary | Creates a dictionary from resources. @exception ArgumentNullException The resources are null. |
Methods
| Method | Description |
|---|---|
| add | Set ICosPdfPrimitive to dictionary. |
| add | Set {@link ICosPdfPrimitive} to dictionary. @exception ArgumentException Throw exception if key/value can’t be edited or removed. |
| addItem | Add item pair. |
| addItem | Add item. |
| clear | Removes all items from the {@link CosPdfDictionary}. |
| contains | Determines whether the CosPdfDictionary contains a specific value. |
| containsItem | Return true if contains item |
| containsKey | Determines whether the {@link CosPdfDictionary} contains an element with the specified key. |
| copyTo | Copies the elements of the CosPdfDictionary to an Array , starting at a particular Array index. |
| copyToTArray | Copy To Array |
| createEmptyDictionary | Creates an empty dictionary that will be attached to the document. |
| createEmptyDictionary | Creates an empty dictionary that will be attached to the page. |
| get_Item | Gets or sets the element with the specified key. |
| getAllKeys | Full collection of keys. Contains editable and not editable keys. |
| getKeys | Collection of editable keys. |
| getValues | Gets an {@link ICollection} containing the values in the {@link CosPdfDictionary}. |
| isReadOnly | Gets a value indicating whether the {@link CosPdfDictionary} is read-only. |
| iterator | Returns an enumerator that iterates through the collection. |
| remove | Removes the first occurrence of a specific object from the CosPdfDictionary . |
| remove | Removes the element with the specified key from the {@link CosPdfDictionary}. |
| removeItem | Remove Item |
| removeItemByKey | Remove item by key. |
| set_Item | Gets or sets the element with the specified key. @exception ArgumentNullException The key is null. @exception KeyNotFoundException The property is retrieved and key is not found. @exception ArgumentException Throw exception if key can’t be edited/set. |
| size | Gets the number of elements contained in the {@link CosPdfDictionary}. |
| toCosPdfDictionary | Tries cast this instance to {@link CosPdfDictionary}. |
| tryGetValue | For access to simple data type like string, name, bool, number. Returns null for other types. |
| tryGetValue | Try to get value |
CosPdfDictionary
Creates a dictionary from resources. @exception ArgumentNullException The resources are null.
add
Set ICosPdfPrimitive to dictionary.
add
Set {@link ICosPdfPrimitive} to dictionary. @exception ArgumentException Throw exception if key/value can’t be edited or removed.
addItem
Add item pair.
addItem
Add item.
clear
public final void clear()
Removes all items from the {@link CosPdfDictionary}.
contains
Determines whether the CosPdfDictionary contains a specific value.
containsItem
Return true if contains item
containsKey
Determines whether the {@link CosPdfDictionary} contains an element with the specified key.
copyTo
Copies the elements of the CosPdfDictionary to an Array , starting at a particular Array index.
copyToTArray
Copy To Array
createEmptyDictionary
Creates an empty dictionary that will be attached to the document.
createEmptyDictionary
Creates an empty dictionary that will be attached to the page.
get_Item
Gets or sets the element with the specified key.
getAllKeys
public final com.aspose.ms.System.Collections.Generic.IGenericCollection< String > getAllKeys()
Full collection of keys. Contains editable and not editable keys.
Returns: List of String values
getKeys
public final com.aspose.ms.System.Collections.Generic.IGenericCollection< String > getKeys()
Collection of editable keys.
Returns: List of String values
getValues
public final com.aspose.ms.System.Collections.Generic.IGenericCollection< ICosPdfPrimitive > getValues()
Gets an {@link ICollection} containing the values in the {@link CosPdfDictionary}.
Returns: List of ICosPdfPrimitive instances
isReadOnly
public final boolean isReadOnly()
Gets a value indicating whether the {@link CosPdfDictionary} is read-only.
Returns: true if the {@link CosPdfDictionary} is read-only; otherwise, false.
iterator
public final com.aspose.ms.System.Collections.Generic.IGenericEnumerator<com.aspose.ms.System.Collections.Generic.KeyValuePair< String , ICosPdfPrimitive >> iterator()
Returns an enumerator that iterates through the collection.
Returns: An enumerator that can be used to iterate through the collection.
remove
Removes the first occurrence of a specific object from the CosPdfDictionary .
remove
Removes the element with the specified key from the {@link CosPdfDictionary}.
removeItem
Remove Item
removeItemByKey
Remove item by key.
set_Item
Gets or sets the element with the specified key. @exception ArgumentNullException The key is null. @exception KeyNotFoundException The property is retrieved and key is not found. @exception ArgumentException Throw exception if key can’t be edited/set.
size
public final int size()
Gets the number of elements contained in the {@link CosPdfDictionary}.
Returns: int value
toCosPdfDictionary
public CosPdfDictionary toCosPdfDictionary()
Tries cast this instance to {@link CosPdfDictionary}.
Returns: null if instance is not {@link CosPdfDictionary} else {@link CosPdfDictionary}.
tryGetValue
For access to simple data type like string, name, bool, number. Returns null for other types.
tryGetValue
Try to get value