json_utils Module
Functions
add_attrib
Add the value of the attribute from the object to the dictionary.
Used to dynamically add the value of the attribute if the value is present.
add_attrib(json_dict: Dict[str, Any], object_, attribute_name: str, alt_name: str = None)
Parameters
| Name | Description |
|---|---|
|
json_dict
Required
|
<xref:<xref:azure.durable_functions.models.utils.json_utils.The dictionary> to <xref:azure.durable_functions.models.utils.json_utils.add the attribute to>>
|
|
object
Required
|
<xref:<xref:azure.durable_functions.models.utils.json_utils.The object> to <xref:azure.durable_functions.models.utils.json_utils.look for the attribute on>>
|
|
attribute_name
Required
|
<xref:<xref:azure.durable_functions.models.utils.json_utils.The name> of <xref:azure.durable_functions.models.utils.json_utils.the attribute> to <xref:azure.durable_functions.models.utils.json_utils.look for>>
|
|
alt_name
|
<xref:azure.durable_functions.models.utils.json_utils.An alternate name> to <xref:azure.durable_functions.models.utils.json_utils.provide> to <xref:azure.durable_functions.models.utils.json_utils.the attribute in the in the dictionary>
Default value: None
|
|
object_
Required
|
|
add_datetime_attrib
Add the value of the attribute from the object to the dictionary converted into a string.
add_datetime_attrib(json_dict: Dict[str, Any], object_, attribute_name: str, alt_name: str = None)
Parameters
| Name | Description |
|---|---|
|
json_dict
Required
|
<xref:<xref:azure.durable_functions.models.utils.json_utils.The dictionary> to <xref:azure.durable_functions.models.utils.json_utils.add the attribute to>>
|
|
object
Required
|
<xref:<xref:azure.durable_functions.models.utils.json_utils.The object> to <xref:azure.durable_functions.models.utils.json_utils.look for the attribute on>>
|
|
attribute_name
Required
|
<xref:<xref:azure.durable_functions.models.utils.json_utils.The name> of <xref:azure.durable_functions.models.utils.json_utils.the attribute> to <xref:azure.durable_functions.models.utils.json_utils.look for>>
|
|
alt_name
|
<xref:azure.durable_functions.models.utils.json_utils.An alternate name> to <xref:azure.durable_functions.models.utils.json_utils.provide> to <xref:azure.durable_functions.models.utils.json_utils.the attribute in the in the dictionary>
Default value: None
|
|
object_
Required
|
|
add_json_attrib
Add the results of the to_json() function call of the attribute from the object to the dict.
Used to dynamically add the JSON converted value of the attribute if the value is present.
add_json_attrib(json_dict: Dict[str, Any], object_, attribute_name: str, alt_name: str = None)
Parameters
| Name | Description |
|---|---|
|
json_dict
Required
|
<xref:<xref:azure.durable_functions.models.utils.json_utils.The dictionary> to <xref:azure.durable_functions.models.utils.json_utils.add the attribute to>>
|
|
object
Required
|
<xref:<xref:azure.durable_functions.models.utils.json_utils.The object> to <xref:azure.durable_functions.models.utils.json_utils.look for the attribute on>>
|
|
attribute_name
Required
|
<xref:<xref:azure.durable_functions.models.utils.json_utils.The name> of <xref:azure.durable_functions.models.utils.json_utils.the attribute> to <xref:azure.durable_functions.models.utils.json_utils.look for>>
|
|
alt_name
|
<xref:azure.durable_functions.models.utils.json_utils.An alternate name> to <xref:azure.durable_functions.models.utils.json_utils.provide> to <xref:azure.durable_functions.models.utils.json_utils.the attribute in the in the dictionary>
Default value: None
|
|
object_
Required
|
|