dictionary_operations#
Performs some operations on Python dictionaries.
Functions:
|
Get the first dictionary key that matches a value. |
- ansys.fluent.core.utils.dictionary_operations.get_first_dict_key_for_value(input_dict, value)#
Get the first dictionary key that matches a value. Typical usage is where the value is known to be unique in the input dictionary.
- Parameters:
- input_dict
dict - value
Any
- input_dict
- Returns:
AnyKey associated with the first match.
- Raises:
ValueErrorIf the value is absent from the dictionary.