treeschema.catalog.field_value

class FieldValue(field_value_inputs: [<class 'int'>, typing.Dict], data_store_id: int, data_schema_id: int, field_id: int, *args, **kwargs)

Bases: treeschema.catalog.base_serializer.TreeSchemaSerializer

An object that represents a single data store.

Create a data field object with either the ID of a data field or the fully defined data field object as a dictionary.

Parameters
  • field_value_inputs – the inputs to create or retrieve the data field value

  • data_store_id – The ID of the data store that this field value belongs to

  • field_id – The ID of the data schema that this field value belongs to

  • field_id – The ID of the data field that this field value belongs to

update(*, field_value: str = None, description: str = None)

Update an existing field value. Only keyword arguments can be provided, positional arguments are not allowed.

Parameters
  • field_value – sample value, must be a Tree Schema field type

  • description – The description for the field value

Returns

a FieldValue, an updated version of itself