DbsStrategy
self, database: IDatabase) dbs_classes.DbsStrategy(
Methods
Name | Description |
---|---|
check_higher_level_usage | Check if a strategy is used in a scenario. |
save | Save an object in the database and all associated files. |
check_higher_level_usage
str) dbs_classes.DbsStrategy.check_higher_level_usage(name:
Check if a strategy is used in a scenario.
Parameters
name :
str
-
name of the strategy to be checked
Returns
:
list
[str
]-
list of scenarios that use the strategy
save
bool = False) dbs_classes.DbsStrategy.save(object_model: Strategy, overwrite:
Save an object in the database and all associated files.
This saves the toml file and any additional files attached to the object.
Parameters
object_model :
Object
-
object to be saved in the database
overwrite :
bool
= False-
whether to overwrite the object if it already exists in the database, by default False
Raises
:
ValueError
-
Raise error if name is already in use.