The DatabaseManagement class is used to create the image database.
More...
|
| string | GetConnectionString (string strName) |
| | Returns the connection string used to connect to the database named 'strName'. More...
|
| |
| virtual void | createTables (SqlConnection connection, bool bFullCreate, bool bUpdateOnly, bool bTemporalOnly=false) |
| | The createTables function creates the tables of the database. More...
|
| |
| virtual void | deleteTables (SqlConnection connection) |
| | The deleteTables function deletes all tables except for the DatasetCreators table. More...
|
| |
| string | getQueryDatabaseCmd (string strName) |
| | Returns the query database command. More...
|
| |
| string | getCreateDatabaseCmd (string strName, string strPath) |
| | Returns the create database command. More...
|
| |
The DatabaseManagement class is used to create the image database.
Definition at line 14 of file DatabaseManagement.cs.
◆ DatabaseManagement()
| MyCaffe.db.image.DatabaseManagement.DatabaseManagement |
( |
ConnectInfo |
ci, |
|
|
string |
strPath = "" |
|
) |
| |
The DatabaseManagement constructor.
- Parameters
-
| ci | Specifies the connection info (recommended values: db = 'DNN', server = '.') |
| strPath | Specifies the file path where the database should be created. |
Definition at line 29 of file DatabaseManagement.cs.
◆ CreateDatabase()
| Exception MyCaffe.db.image.DatabaseManagement.CreateDatabase |
( |
bool |
bUpdateDatabase = false | ) |
|
The CreateDatabae creates a new instance of the database in Microsoft SQL.
- Parameters
-
| bUpdateDatabase | Specifies to update an existing database. |
- Returns
- Returns null on success, an Exception on error.
Definition at line 118 of file DatabaseManagement.cs.
◆ createTables()
| virtual void MyCaffe.db.image.DatabaseManagement.createTables |
( |
SqlConnection |
connection, |
|
|
bool |
bFullCreate, |
|
|
bool |
bUpdateOnly, |
|
|
bool |
bTemporalOnly = false |
|
) |
| |
|
protectedvirtual |
The createTables function creates the tables of the database.
- Parameters
-
| connection | Specifies the SQL connection. |
| bFullCreate | When true the full database is created, otherwise all tables are created except the DatasetCreators table. |
| bUpdateOnly | When true an existing database is being updated. |
| bTemporalOnly | When true only the temporal tables are created. |
Definition at line 189 of file DatabaseManagement.cs.
◆ CreateTemporalTables()
| void MyCaffe.db.image.DatabaseManagement.CreateTemporalTables |
( |
| ) |
|
◆ DatabaseExists()
| Exception MyCaffe.db.image.DatabaseManagement.DatabaseExists |
( |
out bool |
bExists | ) |
|
Queries whether or not the database exists.
- Parameters
-
| bExists | Returns true if the database exists, false otherwise. |
- Returns
- Returns null on success, an Exception on error.
Definition at line 58 of file DatabaseManagement.cs.
◆ deleteTables()
| virtual void MyCaffe.db.image.DatabaseManagement.deleteTables |
( |
SqlConnection |
connection | ) |
|
|
protectedvirtual |
The deleteTables function deletes all tables except for the DatasetCreators table.
- Parameters
-
| connection | Specifies the SQL connection. |
Definition at line 299 of file DatabaseManagement.cs.
◆ GetConnectionString()
| string MyCaffe.db.image.DatabaseManagement.GetConnectionString |
( |
string |
strName | ) |
|
|
protected |
Returns the connection string used to connect to the database named 'strName'.
- Parameters
-
| strName | Specifies the database name of the database to connect to. |
- Returns
- The connection string is returned.
Definition at line 48 of file DatabaseManagement.cs.
◆ getCreateDatabaseCmd()
| string MyCaffe.db.image.DatabaseManagement.getCreateDatabaseCmd |
( |
string |
strName, |
|
|
string |
strPath |
|
) |
| |
|
protected |
Returns the create database command.
- Parameters
-
| strName | Specifies the database name. |
| strPath | Specifies the file path where the database is to be created. |
- Returns
- The SQL command is returned.
Definition at line 384 of file DatabaseManagement.cs.
◆ getQueryDatabaseCmd()
| string MyCaffe.db.image.DatabaseManagement.getQueryDatabaseCmd |
( |
string |
strName | ) |
|
|
protected |
Returns the query database command.
- Parameters
-
| strName | Specifies the database name. |
- Returns
- The SQL command is returned.
Definition at line 369 of file DatabaseManagement.cs.
◆ PurgeDatabase()
| Exception MyCaffe.db.image.DatabaseManagement.PurgeDatabase |
( |
| ) |
|
The PurgeDatabase function delete the data from the database.
- Returns
- Returns null on success, an Exception on error.
Definition at line 94 of file DatabaseManagement.cs.
◆ m_bUpdateDatabase
| bool MyCaffe.db.image.DatabaseManagement.m_bUpdateDatabase = true |
|
protected |
Specifies whether or not the database is just being updated or not.
Definition at line 22 of file DatabaseManagement.cs.
◆ ConnectInfo
| ConnectInfo MyCaffe.db.image.DatabaseManagement.ConnectInfo |
|
get |
The documentation for this class was generated from the following file: