Свойство | Тип | Описание | |
---|---|---|---|
_cancelled | bool | ||
_defaultValueRx | |||
_isActive | bool | ||
_keyRx |
Метод | Описание | |
---|---|---|
CancelConversion ( ) : void |
Cancels the conversion.
|
|
ConvertToDatabase ( |
This method takes as input the connection to an SQL Server database and creates a corresponding SQLite database file with a schema derived from the SQL Server database. The method continues asynchronously in the background and the caller returned immediatly. |
|
ConvertToDatabase ( string sqlServerConnectionString, |
This method takes as input the connection string to an SQL Server database and creates a corresponding SQLite database file with a schema derived from the SQL Server database. The method continues asynchronously in the background and the caller returned immediatly. |
|
ConvertToDatabase ( string sqlServerConnectionString, string sqliteConnectionString, SqlConversionHandler sqlConversionHandler, SqlTableSelectionHandler sqlTableSelectionHandler, FailedViewDefinitionHandler failedViewDefinitionHandler, bool createTriggers ) : void |
This method takes as input the connection string to an SQL Server database and creates a corresponding SQLite database file with a schema derived from the SQL Server database. The method continues asynchronously in the background and the caller returned immediatly. |
|
InitializeSQLiteConnection ( string sqliteConnectionString ) : |
||
InitializeSQLiteDatabase ( |
||
InitializeSqlServerConnection ( string sqlServerConnectionString ) : |
||
InitializeSqlServerDatabase ( |
Метод | Описание | |
---|---|---|
AddTriggersForForeignKeys ( |
||
AddTriggersForForeignKeys ( string sqlitePath, IEnumerable |
||
AdjustDefaultValue ( string val ) : string |
More adjustments for the DEFAULT value clause.
|
|
BuildIndexSchema ( string indexName, string desc, string keys ) : |
Builds an index schema object from the specified components (Read from SQL Server).
|
|
BuildSQLiteInsert ( |
Creates a command object needed to insert values into a specific SQLite table.
|
|
BuildSQLiteUpdate ( |
Creates a command object needed to insert values into a specific SQLite table.
|
|
BuildSourceTableQuery ( |
Builds a SELECT query for a specific table. Needed in the process of copying rows from the SQL Server database to the SQLite database.
|
|
BuildSqlServerInsert ( |
Creates a command object needed to insert values into a specific SQLite table.
|
|
CastValueForColumn ( object val, ColumnSchema columnSchema ) : object |
Used in order to adjust the value received from SQL Servr for the SQLite database.
|
|
CheckCancelled ( ) : void |
Convenience method for checking if the conversion progress needs to be cancelled.
|
|
ConvertSourceDatabaseToDestination ( |
Do the entire process of first reading the SQL Server schema, creating a corresponding SQLite schema, and copying all rows from the SQL Server database to the SQLite database.
|
|
CopySourceDatabaseRowsToDestination ( |
Copies table rows from the SQL Server database to the SQLite database.
|
|
CreateForeignKeySchema ( IDbConnection sourceConnection, |
Add foreign key schema object from the specified components (Read from SQL Server).
|
|
CreateSQLiteConnectionString ( string sqlitePath, string password ) : string |
Creates SQLite connection string from the specified DB file path.
|
|
CreateSQLiteDatabase ( |
Creates the SQLite database.
|
|
CreateSQLiteDatabase ( string sqlitePath, DatabaseSchema schema, string password, SqlConversionHandler handler, FailedViewDefinitionHandler viewFailureHandler ) : void |
Creates the SQLite database from the schema read from the SQL Server.
|
|
CreateSqlServerConnectionString ( string sqlitePath, string password ) : string |
Creates SQLite connection string from the specified DB file path.
|
|
CreateSqlServerDatabase ( |
Creates the SQLite database.
|
|
CreateSqlServerDatabase ( string sqlitePath, DatabaseSchema schema, string password, SqlConversionHandler handler, FailedViewDefinitionHandler viewFailureHandler ) : void |
Creates the SQLite database from the schema read from the SQL Server.
|
|
CreateTableSchema ( IDbConnection sourceConnection, string tableName, string tableSchemaName ) : |
Creates a TableSchema object using the specified SQL Server connection and the name of the table for which we need to create the schema.
|
|
FixDefaultValueString ( string colDefault ) : string |
Does some necessary adjustments to a value string that appears in a column DEFAULT clause.
|
|
GetDbTypeOfColumn ( ColumnSchema columnSchema ) : DbType |
Matches SQL Server types to general DB types
|
|
GetNormalizedName ( string str, List |
Used in order to avoid breaking naming rules (e.g., when a table has a name in SQL Server that cannot be used as a basis for a matching index name in SQLite).
|
|
ParseBlobAsGuid ( byte blob ) : System.Guid | ||
ParseStringAsGuid ( string str ) : System.Guid | ||
ReadSourceSchema ( |
Reads the entire SQL Server DB schema using the specified connection string.
|
|
ValidateDataType ( string dataType ) : void |
Small validation method to make sure we don't miss anything without getting an exception.
|
|
WriteTriggerSchema ( TriggerSchema ts ) : string |
Gets a create script for the triggerSchema in SQLite syntax
|
Метод | Описание | |
---|---|---|
AddSQLiteTable ( |
Creates the CREATE TABLE DDL for SQLite and a specific table.
|
|
AddSQLiteView ( |
||
AddTableTriggers ( |
||
BuildColumnStatement ( ColumnSchema col, |
Used when creating the CREATE TABLE DDL. Creates a single row for the specified column.
|
|
BuildCreateIndex ( string tableName, |
Creates a CREATE INDEX DDL for the specified table and index schema.
|
|
BuildCreateTableQuery ( |
returns the CREATE TABLE DDL for creating the SQLite table from the specified table schema object.
|
|
DiscardNational ( string value ) : string |
Discards the national prefix if exists (e.g., N'sometext') which is not supported in SQLite.
|
|
IsSingleQuoted ( string value ) : bool | ||
IsValidDefaultValue ( string value ) : bool |
Check if the DEFAULT clause is valid by SQLite standards
|
|
StripParens ( string value ) : string |
Strip any parentheses from the string.
|
protected static AddTriggersForForeignKeys ( |
||
sqliteConnection | ||
schema | IEnumerable |
|
handler | SqlConversionHandler | |
Результат | void |
protected static AddTriggersForForeignKeys ( string sqlitePath, IEnumerable |
||
sqlitePath | string | |
schema | IEnumerable |
|
password | string | |
handler | SqlConversionHandler | |
Результат | void |
protected static AdjustDefaultValue ( string val ) : string | ||
val | string | The value to adjust |
Результат | string |
protected static BuildIndexSchema ( string indexName, string desc, string keys ) : |
||
indexName | string | The name of the index |
desc | string | The description of the index |
keys | string | Key columns that are part of the index. |
Результат |
protected static BuildSQLiteInsert ( |
||
ts | The table schema object for the table. | |
Результат |
protected static BuildSQLiteUpdate ( |
||
ts | The table schema object for the table. | |
Результат |
protected abstract BuildSourceTableQuery ( |
||
tableSchema | ||
Результат | string |
protected static BuildSqlServerInsert ( |
||
ts | The table schema object for the table. | |
Результат |
protected static CastValueForColumn ( object val, ColumnSchema columnSchema ) : object | ||
val | object | The value object |
columnSchema | ColumnSchema | The corresponding column schema |
Результат | object |
protected static CheckCancelled ( ) : void | ||
Результат | void |
protected abstract ConvertSourceDatabaseToDestination ( |
||
sqlConnection | The SQL connection. | |
sqliteConnection | The SQLite connection. | |
sqlConversionHandler | SqlConversionHandler | The SQL conversion handler. |
sqlTableSelectionHandler | SqlTableSelectionHandler | The SQL table selection handler. |
failedViewDefinitionHandler | FailedViewDefinitionHandler | The failed view definition handler. |
createTriggers | bool | if set to |
Результат | void |
public abstract ConvertToDatabase ( |
||
sqlConnection | The SQL connection. | |
sqliteConnection | The SQLite connection. | |
sqlConversionHandler | SqlConversionHandler | The SQL conversion handler. |
sqlTableSelectionHandler | SqlTableSelectionHandler | The SQL table selection handler. |
failedViewDefinitionHandler | FailedViewDefinitionHandler | The failed view definition handler. |
createTriggers | bool | if set to |
Результат | void |
public abstract ConvertToDatabase ( string sqlServerConnectionString, |
||
sqlServerConnectionString | string | The connection string to the SQL Server database. |
sqliteConnection | The path to the SQLite database file that needs to get created. | |
sqlConversionHandler | SqlConversionHandler | The SQL conversion handler. |
sqlTableSelectionHandler | SqlTableSelectionHandler | The SQL table selection handler. |
failedViewDefinitionHandler | FailedViewDefinitionHandler | The failed view definition handler. |
createTriggers | bool | if set to |
Результат | void |
public abstract ConvertToDatabase ( string sqlServerConnectionString, string sqliteConnectionString, SqlConversionHandler sqlConversionHandler, SqlTableSelectionHandler sqlTableSelectionHandler, FailedViewDefinitionHandler failedViewDefinitionHandler, bool createTriggers ) : void | ||
sqlServerConnectionString | string | The connection string to the SQL Server database. |
sqliteConnectionString | string | The connection string to the SQLite database. |
sqlConversionHandler | SqlConversionHandler | The SQL conversion handler. |
sqlTableSelectionHandler | SqlTableSelectionHandler | |
failedViewDefinitionHandler | FailedViewDefinitionHandler | The failed view definition handler. |
createTriggers | bool | if set to |
Результат | void |
protected abstract CopySourceDatabaseRowsToDestination ( |
||
sqlConnection | The SQL connection. | |
sqliteConnection | The SQLite connection. | |
schema | List |
The schema of the SQL Server database. |
handler | SqlConversionHandler | A handler to handle progress notifications. |
Результат | void |
protected abstract CreateForeignKeySchema ( IDbConnection sourceConnection, |
||
sourceConnection | IDbConnection | |
tableSchema | ||
Результат | void |
protected static CreateSQLiteConnectionString ( string sqlitePath, string password ) : string | ||
sqlitePath | string | The path to the SQLite database file. |
password | string | |
Результат | string |
protected static CreateSQLiteDatabase ( |
||
sqliteConnection | The SQLite connection. | |
schema | DatabaseSchema | The schema. |
handler | SqlConversionHandler | The handler. |
viewFailureHandler | FailedViewDefinitionHandler | The view failure handler. |
Результат | void |
protected static CreateSQLiteDatabase ( string sqlitePath, DatabaseSchema schema, string password, SqlConversionHandler handler, FailedViewDefinitionHandler viewFailureHandler ) : void | ||
sqlitePath | string | The path to the generated DB file. |
schema | DatabaseSchema | The schema of the SQL server database. |
password | string | The password to use for encrypting the DB or null if non is needed. |
handler | SqlConversionHandler | A handle for progress notifications. |
viewFailureHandler | FailedViewDefinitionHandler | |
Результат | void |
protected static CreateSqlServerConnectionString ( string sqlitePath, string password ) : string | ||
sqlitePath | string | The path to the SQLite database file. |
password | string | |
Результат | string |
protected static CreateSqlServerDatabase ( |
||
sqliteConnection | The SQLite connection. | |
schema | DatabaseSchema | The schema. |
handler | SqlConversionHandler | The handler. |
viewFailureHandler | FailedViewDefinitionHandler | The view failure handler. |
Результат | void |
protected static CreateSqlServerDatabase ( string sqlitePath, DatabaseSchema schema, string password, SqlConversionHandler handler, FailedViewDefinitionHandler viewFailureHandler ) : void | ||
sqlitePath | string | The path to the generated DB file. |
schema | DatabaseSchema | The schema of the SQL server database. |
password | string | The password to use for encrypting the DB or null if non is needed. |
handler | SqlConversionHandler | A handle for progress notifications. |
viewFailureHandler | FailedViewDefinitionHandler | |
Результат | void |
protected abstract CreateTableSchema ( IDbConnection sourceConnection, string tableName, string tableSchemaName ) : |
||
sourceConnection | IDbConnection | |
tableName | string | The name of the table for which we wants to create the table schema. |
tableSchemaName | string | |
Результат |
protected static FixDefaultValueString ( string colDefault ) : string | ||
colDefault | string | The original default value string (as read from SQL Server). |
Результат | string |
protected static GetDbTypeOfColumn ( ColumnSchema columnSchema ) : DbType | ||
columnSchema | ColumnSchema | The column schema to use for the match |
Результат | DbType |
protected static GetNormalizedName ( string str, List |
||
str | string | The name to change if necessary |
names | List |
Used to avoid duplicate names |
Результат | string |
public InitializeSQLiteConnection ( string sqliteConnectionString ) : |
||
sqliteConnectionString | string | |
Результат |
public InitializeSQLiteDatabase ( |
||
sqliteConnection | ||
PragmaCommands | List |
|
Результат | void |
public InitializeSqlServerConnection ( string sqlServerConnectionString ) : |
||
sqlServerConnectionString | string | |
Результат |
public InitializeSqlServerDatabase ( |
||
sqlConnection | ||
Результат | void |
protected static ParseBlobAsGuid ( byte blob ) : System.Guid | ||
blob | byte | |
Результат | System.Guid |
protected static ParseStringAsGuid ( string str ) : System.Guid | ||
str | string | |
Результат | System.Guid |
protected abstract ReadSourceSchema ( |
||
sqlConnection | The SQL connection. | |
sqlConversionHandler | SqlConversionHandler | The SQL conversion handler. |
sqlTableSelectionHandler | SqlTableSelectionHandler | The SQL table selection handler. |
Результат | DatabaseSchema |
protected static ValidateDataType ( string dataType ) : void | ||
dataType | string | The datatype to validate. |
Результат | void |
protected static WriteTriggerSchema ( TriggerSchema ts ) : string | ||
ts | TriggerSchema | Trigger to script |
Результат | string |
protected static Regex,System.Text.RegularExpressions _defaultValueRx | ||
Результат |