Craig's Utility Library
4.0 Beta
|
SQL Server schema generator More...
Public Member Functions | |
SQLServerSchemaGenerator (QueryProvider.Manager Provider, SourceProvider.Manager SourceProvider) | |
Constructor More... | |
IEnumerable< string > | GenerateSchema (ISource DesiredStructure, ISourceInfo Source) |
Generates a list of commands used to modify the source. If it does not exist prior, the commands will create the source from scratch. Otherwise the commands will only add new fields, tables, etc. It does not delete old fields. More... | |
ISource | GetSourceStructure (ISourceInfo Source) |
Gets the structure of a source More... | |
void | Setup (ListMapping< IDatabase, IMapping > Mappings, IDatabase Database, QueryProvider.Manager QueryProvider, Graph< IMapping > Structure) |
Sets up the specified database schema More... | |
bool | SourceExists (string Source, ISourceInfo Info) |
Checks if a source exists More... | |
bool | StoredProcedureExists (string StoredProcedure, ISourceInfo Source) |
Checks if a stored procedure exists More... | |
bool | TableExists (string Table, ISourceInfo Source) |
Checks if a table exists More... | |
bool | TriggerExists (string Trigger, ISourceInfo Source) |
Checks if a trigger exists More... | |
bool | ViewExists (string View, ISourceInfo Source) |
Checks if a view exists More... | |
Properties | |
string | ProviderName [get] |
Provider name associated with the schema generator More... | |
QueryProvider.Manager | Provider [get] |
Query provider object More... | |
SourceProvider.Manager | SourceProvider [get] |
Source provider object More... | |
Properties inherited from Utilities.ORM.Manager.Schema.Interfaces.ISchemaGenerator | |
string | ProviderName [get] |
Provider name associated with the schema generator More... | |
SQL Server schema generator
Definition at line 45 of file SQLServerSchemaGenerator.cs.
Utilities.ORM.Manager.Schema.Default.Database.SQLServer.SQLServerSchemaGenerator.SQLServerSchemaGenerator | ( | QueryProvider.Manager | Provider, |
SourceProvider.Manager | SourceProvider | ||
) |
Constructor
Provider | The provider. |
SourceProvider | The source provider. |
Definition at line 52 of file SQLServerSchemaGenerator.cs.
IEnumerable<string> Utilities.ORM.Manager.Schema.Default.Database.SQLServer.SQLServerSchemaGenerator.GenerateSchema | ( | ISource | DesiredStructure, |
ISourceInfo | Source | ||
) |
Generates a list of commands used to modify the source. If it does not exist prior, the commands will create the source from scratch. Otherwise the commands will only add new fields, tables, etc. It does not delete old fields.
DesiredStructure | Desired source structure |
Source | Source to use |
Implements Utilities.ORM.Manager.Schema.Interfaces.ISchemaGenerator.
Definition at line 81 of file SQLServerSchemaGenerator.cs.
ISource Utilities.ORM.Manager.Schema.Default.Database.SQLServer.SQLServerSchemaGenerator.GetSourceStructure | ( | ISourceInfo | Source | ) |
Gets the structure of a source
Source | Source to use |
Implements Utilities.ORM.Manager.Schema.Interfaces.ISchemaGenerator.
Definition at line 92 of file SQLServerSchemaGenerator.cs.
void Utilities.ORM.Manager.Schema.Default.Database.SQLServer.SQLServerSchemaGenerator.Setup | ( | ListMapping< IDatabase, IMapping > | Mappings, |
IDatabase | Database, | ||
QueryProvider.Manager | QueryProvider, | ||
Graph< IMapping > | Structure | ||
) |
Sets up the specified database schema
Mappings | The mappings. |
Database | The database. |
QueryProvider | The query provider. |
Structure | The structure. |
Implements Utilities.ORM.Manager.Schema.Interfaces.ISchemaGenerator.
Definition at line 123 of file SQLServerSchemaGenerator.cs.
bool Utilities.ORM.Manager.Schema.Default.Database.SQLServer.SQLServerSchemaGenerator.SourceExists | ( | string | Source, |
ISourceInfo | Info | ||
) |
Checks if a source exists
Source | Source to check |
Info | Source info to use |
Implements Utilities.ORM.Manager.Schema.Interfaces.ISchemaGenerator.
Definition at line 171 of file SQLServerSchemaGenerator.cs.
bool Utilities.ORM.Manager.Schema.Default.Database.SQLServer.SQLServerSchemaGenerator.StoredProcedureExists | ( | string | StoredProcedure, |
ISourceInfo | Source | ||
) |
Checks if a stored procedure exists
StoredProcedure | Stored procedure to check |
Source | Source to use |
Implements Utilities.ORM.Manager.Schema.Interfaces.ISchemaGenerator.
Definition at line 182 of file SQLServerSchemaGenerator.cs.
bool Utilities.ORM.Manager.Schema.Default.Database.SQLServer.SQLServerSchemaGenerator.TableExists | ( | string | Table, |
ISourceInfo | Source | ||
) |
Checks if a table exists
Implements Utilities.ORM.Manager.Schema.Interfaces.ISchemaGenerator.
Definition at line 193 of file SQLServerSchemaGenerator.cs.
bool Utilities.ORM.Manager.Schema.Default.Database.SQLServer.SQLServerSchemaGenerator.TriggerExists | ( | string | Trigger, |
ISourceInfo | Source | ||
) |
Checks if a trigger exists
Implements Utilities.ORM.Manager.Schema.Interfaces.ISchemaGenerator.
Definition at line 204 of file SQLServerSchemaGenerator.cs.
bool Utilities.ORM.Manager.Schema.Default.Database.SQLServer.SQLServerSchemaGenerator.ViewExists | ( | string | View, |
ISourceInfo | Source | ||
) |
Checks if a view exists
Implements Utilities.ORM.Manager.Schema.Interfaces.ISchemaGenerator.
Definition at line 215 of file SQLServerSchemaGenerator.cs.
|
getprotected |
Query provider object
Definition at line 66 of file SQLServerSchemaGenerator.cs.
|
get |
Provider name associated with the schema generator
Definition at line 61 of file SQLServerSchemaGenerator.cs.
|
getprotected |
Source provider object
Definition at line 71 of file SQLServerSchemaGenerator.cs.