다음을 통해 공유


BuildDictMeta Class

BuildDictMeta will apply to every binding. It will apply add_to_dict decorator to <xref:azure.functions.decorators.utils.BuildDictMeta.__init__> of every binding class to collect list of params to include in building json dictionary which corresponds to function.json in legacy app. It will also apply skip_none to <xref:azure.functions.decorators.utils.BuildDictMeta.get_dict_repr> to enable json dictionary generated for every binding has non-empty value fields. It is needed for enabling binding param optionality.

Constructor

BuildDictMeta(name, bases, dct)

Parameters

Name Description
mcs
Required
name
Required
bases
Required
dct
Required

Methods

add_to_dict
clean_nones

Recursively remove all None values from dictionaries and lists, and returns the result as a new dictionary or list.

mro

Return a type's method resolution order.

skip_none

add_to_dict

static add_to_dict(func: Callable[[...], Any])

Parameters

Name Description
func
Required

clean_nones

Recursively remove all None values from dictionaries and lists, and returns the result as a new dictionary or list.

static clean_nones(value)

Parameters

Name Description
value
Required

mro

Return a type's method resolution order.

mro()

skip_none

static skip_none(func)

Parameters

Name Description
func
Required