Options
All
  • Public
  • Public/Protected
  • All
Menu

Organizes communication with sqlite DBMS.

Hierarchy

Implements

Index

Constructors

constructor

Properties

connection

connection: Connection

Connection used by driver.

dataTypeDefaults

dataTypeDefaults: DataTypeDefaults

Default values of length, precision and scale depends on column data type. Used in the cases when length/precision/scale is not specified by user.

Optional database

database: undefined | string

Master database used to perform all write queries.

databaseConnection

databaseConnection: any

Real database connection with sqlite database.

isReplicated

isReplicated: boolean = false

Indicates if replication is enabled.

options

Connection options.

Optional queryRunner

queryRunner: QueryRunner

Sqlite has a single QueryRunner because it works on a single database connection.

spatialTypes

spatialTypes: ColumnType[] = []

Gets list of spatial column data types.

sqlite

sqlite: any

SQLite underlying library.

supportedDataTypes

supportedDataTypes: ColumnType[] = ["int","integer","tinyint","smallint","mediumint","bigint","unsigned big int","int2","int8","integer","character","varchar","varying character","nchar","native character","nvarchar","text","clob","text","blob","real","double","double precision","float","real","numeric","decimal","boolean","date","time","datetime"]

Gets list of supported column data types by a driver.

see

https://www.tutorialspoint.com/sqlite/sqlite_data_types.htm

see

https://sqlite.org/datatype3.html

treeSupport

treeSupport: boolean = true

Indicates if tree tables are supported by this driver.

withLengthColumnTypes

withLengthColumnTypes: ColumnType[] = ["character","varchar","varying character","nchar","native character","nvarchar","text","blob","clob"]

Gets list of column data types that support length by a driver.

withPrecisionColumnTypes

withPrecisionColumnTypes: ColumnType[] = []

Gets list of column data types that support precision by a driver.

withScaleColumnTypes

withScaleColumnTypes: ColumnType[] = []

Gets list of column data types that support scale by a driver.

Methods

afterConnect

  • afterConnect(): Promise<void>

buildTableName

  • buildTableName(tableName: string, schema?: undefined | string, database?: undefined | string): string

connect

  • connect(): Promise<void>

Protected createDatabaseConnection

  • createDatabaseConnection(): Promise<void>

Protected createDatabaseDirectory

  • createDatabaseDirectory(fullPath: string): Promise<void>

createFullType

createGeneratedMap

  • createGeneratedMap(metadata: EntityMetadata, insertResult: any): any

createParameter

  • createParameter(parameterName: string, index: number): string

createQueryRunner

  • createQueryRunner(mode?: "master" | "slave"): QueryRunner

createSchemaBuilder

disconnect

  • disconnect(): Promise<void>

escape

  • escape(columnName: string): string

escapeQueryWithParameters

findChangedColumns

getColumnLength

isReturningSqlSupported

  • isReturningSqlSupported(): boolean

isUUIDGenerationSupported

  • isUUIDGenerationSupported(): boolean

Protected loadDependencies

  • loadDependencies(): void

normalizeDefault

normalizeIsUnique

normalizeType

  • normalizeType(column: object): string

obtainMasterConnection

  • obtainMasterConnection(): Promise<any>

obtainSlaveConnection

  • obtainSlaveConnection(): Promise<any>

prepareHydratedValue

  • prepareHydratedValue(value: any, columnMetadata: ColumnMetadata): any

preparePersistentValue

  • preparePersistentValue(value: any, columnMetadata: ColumnMetadata): any

Object literals

mappedDataTypes

mappedDataTypes: object

Orm has special columns and we need to know what database column types should be for those types. Column types are driver dependant.

cacheDuration

cacheDuration: "int" = "int"

cacheId

cacheId: "int" = "int"

cacheIdentifier

cacheIdentifier: "varchar" = "varchar"

cacheQuery

cacheQuery: "text" = "text"

cacheResult

cacheResult: "text" = "text"

cacheTime

cacheTime: "bigint" = "bigint"

createDate

createDate: "datetime" = "datetime"

createDateDefault

createDateDefault: string = "datetime('now')"

migrationId

migrationId: "integer" = "integer"

migrationName

migrationName: "varchar" = "varchar"

migrationTimestamp

migrationTimestamp: "bigint" = "bigint"

treeLevel

treeLevel: "integer" = "integer"

updateDate

updateDate: "datetime" = "datetime"

updateDateDefault

updateDateDefault: string = "datetime('now')"

version

version: "integer" = "integer"

Generated using TypeDoc