heat.objects.fields.
Json
[source]¶Bases: oslo_versionedobjects.fields.FieldType
coerce
(obj, attr, value)[source]¶This is called to coerce (if possible) a value on assignment.
This method should convert the value given into the designated type, or throw an exception if this is not possible.
:param:obj: The VersionedObject on which an attribute is being set :param:attr: The name of the attribute being set :param:value: The value being set :returns: A properly-typed value
from_primitive
(obj, attr, value)[source]¶This is called to deserialize a value.
This method should deserialize a value from the form given by to_primitive() to the designated type.
:param:obj: The VersionedObject on which the value is to be set :param:attr: The name of the attribute which will hold the value :param:value: The serialized form of the value :returns: The natural form of the value
to_primitive
(obj, attr, value)[source]¶This is called to serialize a value.
This method should serialize a value to the form expected by from_primitive().
:param:obj: The VersionedObject on which the value is set :param:attr: The name of the attribute holding the value :param:value: The natural form of the value :returns: The serialized form of the value
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.