get_attrs

get dict of attribute names and values

Generates a dictionary of the MaciDataObj's current attribute names and values, and returns a dict. This method currently has no parameters.

Useful if it is desired to view or pull all current attribute names and values on the object.

data.get_attrs() -> dict[str, Any]

Basic Example of getting a dictionary of the current attribute names/values of the MaciDataObj

dict_data = data.get_attrs()

In this example, we simply use the get_attrs method on the MaciDataObj to get a generated copy of the current attribute names and values, currently held inside the maci object, to receive a dictionary representing the attribute names as key names and their respective associated values, and assign the returned dict data to a variable.

Last updated