Class ObjectDictionary
Controlled low-level dictionary editing surface for advanced PDF scenarios.
Inheritance
ObjectDictionary
Assembly: DRIT.Pdf.dll
Syntax
public sealed class ObjectDictionary
Methods
ContainsKey(string)
Returns true when the dictionary contains the given key.
Declaration
public bool ContainsKey(string key)
Parameters
| Type |
Name |
Description |
| string |
key |
|
Returns
GetBoolean(string)
Gets a boolean value for the given key, or null when absent/non-boolean.
Declaration
public bool? GetBoolean(string key)
Parameters
| Type |
Name |
Description |
| string |
key |
|
Returns
GetDictionary(string)
Retrieves a nested dictionary by key if present; returns null when absent.
Supports direct and indirect dictionary values.
Declaration
public ObjectDictionary? GetDictionary(string key)
Parameters
| Type |
Name |
Description |
| string |
key |
|
Returns
GetOrAddDictionary(string, bool)
Gets an existing nested dictionary, or creates one when missing.
Declaration
public ObjectDictionary GetOrAddDictionary(string key, bool indirect = true)
Parameters
Returns
GetString(string)
Gets a textual representation for a value stored under the given key.
Declaration
public string? GetString(string key)
Parameters
| Type |
Name |
Description |
| string |
key |
|
Returns
Remove(string)
Removes a key from the dictionary when present.
Declaration
public void Remove(string key)
Parameters
| Type |
Name |
Description |
| string |
key |
|
SetBoolean(string, bool)
Sets a boolean value for the given key.
Declaration
public void SetBoolean(string key, bool value)
Parameters
SetDate(string, DateTime)
Sets a date value in PDF date string format.
Declaration
public void SetDate(string key, DateTime value)
Parameters
SetInteger(string, long)
Sets an integer value for the given key.
Declaration
public void SetInteger(string key, long value)
Parameters
SetName(string, string)
Sets a name object value for the given key.
Declaration
public void SetName(string key, string value)
Parameters
SetString(string, string)
Sets a literal string value for the given key.
Declaration
public void SetString(string key, string value)
Parameters