data_store
¶
Module for data store class.
authors: |
|
---|---|
date: | 18.12.2017 |
Module Contents¶
-
class
data_store.
DataStore
(toolbox, name, description, url, x, y)[source]¶ Bases:
project_item.ProjectItem
Data Store class.
-
name
¶ Object name
Type: str
-
description
¶ Object description
Type: str
-
x
¶ Initial X coordinate of item icon
Type: int
-
y
¶ Initial Y coordinate of item icon
Type: int
-
make_signal_handler_dict
(self)[source]¶ Returns a dictionary of all shared signals and their handlers. This is to enable simpler connecting and disconnecting.
-
url
(self)[source] Return the url attribute, for saving the project.
-
make_url
(self, log_errors=True)[source]¶ Return a sqlalchemy url from the current url attribute or None if not valid.
-
open_sqlite_file
(self, checked=False)[source]¶ Open file browser where user can select the path to an SQLite file that they want to use.
-
load_url_into_selections
(self)[source]¶ Load url attribute into shared widget selections. Used when activating the item, and creating a new Spine db.
-
enable_no_dialect
(self)[source]¶ Adjust widget enabled status to default when no dialect is selected.
-
check_dialect
(self, dialect)[source]¶ Check if selected dialect is supported. Offer to install DBAPI if not.
Returns: True if dialect is supported, False if not.
-
install_dbapi_conda
(self, dbapi)[source]¶ Install DBAPI using conda. Fails if conda is not installed.
-
open_directory
(self, checked=False)[source]¶ Open file explorer in this Data Store’s data directory.
-
do_create_new_spine_database
(self, url, for_spine_model)[source]¶ Separate method so ‘busy_effect’ don’t overlay any message box.
-