mdsuite.database.types module

MDSuite: A Zincwarecode package.

License

This program and the accompanying materials are made available under the terms of the Eclipse Public License v2.0 which accompanies this distribution, and is available at https://www.eclipse.org/legal/epl-v20.html

SPDX-License-Identifier: EPL-2.0

Copyright Contributors to the Zincwarecode Project.

Contact Information

email: zincwarecode@gmail.com github: https://github.com/zincware web: https://zincwarecode.com/

Citation

If you use this module please cite us with:

Summary

class mdsuite.database.types.JSONEncodedDict(*args, **kwargs)[source]

Bases: TypeDecorator

Represents an immutable structure as a json-encoded string.

impl

alias of VARCHAR

process_bind_param(value: dict, dialect)[source]

Provide a bound value processing function.

Convert a dictionary to a json string and store the string in the database

process_result_value(value, dialect) dict[source]

Receive a result-row column value to be converted.

Convert a loaded string from the database into a dict object

class mdsuite.database.types.MutableDict[source]

Bases: Mutable, dict

Subclassed version of a dictionary used in the database.

classmethod coerce(key, value)[source]

Convert plain dictionaries to MutableDict.