Method GetBoolean
GetBoolean(string, bool, bool)
Gets the boolean value that corresponds to the specified key. If the key does not exist and create is false, the function returns the defaultValue. If the key does not exist and create is true, a direct value will be created using the defaultValue. If the key exists but the value is neither a boolean nor a PDF reference to a boolean, the function throws an InvalidOperationException.
public bool GetBoolean(string key, bool create = false, bool defaultValue = false)
Parameters
keystringcreatebooldefaultValuebool
Returns
- bool