mdsuite.database.database_base 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.database_base.DatabaseBase(database_name: str)[source]¶
Bases:
object
Docstring.
- property base: declarative_base¶
rtype: Get the declarative base from the Database scheme
- property engine: Engine¶
Create a SQLAlchemy Engine.
- Return type:
a SQLAlchemy Engine connected to the Database
- property session: Session¶
Notes
Use with context manager like: >>> with self.session as ses: >>> ses.add()
- Return type:
Session that can be used inside a context manager