Data Container¶
-
class
hal_py.
DataContainer
¶ Container to hold data that is associated with an entity.
-
data
¶ A dict from ((1) category, (2) key) to ((1) type, (2) value) containing all stored data entries.
Type: dict[tuple(str,str),tuple(str,str)]
-
delete_data
(self: hal_py.DataContainer, category: str, key: str, log_with_info_level: bool = False) → bool¶ Delete a data entry.
Parameters: Returns: True on success, false otherwise.
Return type:
-
get_data
(self: hal_py.DataContainer, category: str, key: str) → Tuple[str, str]¶ Get the data entry specified by the given category and key.
Parameters: Returns: The tuple ((1) type, (2) value).
Return type:
-
get_data_map
(self: hal_py.DataContainer) → Dict[Tuple[str, str], Tuple[str, str]]¶ Get a dict from ((1) category, (2) key) to ((1) type, (2) value) containing all stored data entries.
Returns: The stored data as a dict. Return type: dict[tuple(str,str),tuple(str,str)]
-
has_data
(self: hal_py.DataContainer, category: str, key: str) → bool¶ Determine whether an entry of given category and key exists.
Parameters: Returns: True if the entry exists, False otherwise.
Return type:
-
set_data
(self: hal_py.DataContainer, category: str, key: str, data_type: str, value: str, log_with_info_level: bool = False) → bool¶ Add a data entry.<br> May overwrite an existing entry.
Parameters: Returns: True on success, false otherwise.
Return type:
-