C# Класс Azavea.Open.DAO.SQLite.SQLiteDaLayer

Implements a FastDao layer customized for PostGreSQL (optionally with PostGIS installed).
Наследование: Azavea.Open.DAO.SQL.SqlDaDdlLayer
Показать файл Открыть проект

Открытые методы

Метод Описание
CreateStoreHouse ( ) : void

Creates the store house specified in the connection descriptor. If this data source doesn't use a store house, this method should be a no-op. If this data source DOES use store houses, but support for adding them is not implemented yet, this should throw a NotImplementedException. Store house typically corresponds to "database". For SQLite this creates a blank database file (no tables).

DeleteStoreHouse ( ) : void

Deletes the store house specified in the connection descriptor. If this data source doesn't use a store house, this method should be a no-op. If this data source DOES use store houses, but support for dropping them is not implemented yet, this should throw a NotImplementedException. Store house typically corresponds to "database". If there is no store house with the given name, this should be a no-op. For SQLite, this just deletes the database file.

SQLiteDaLayer ( SQLiteDescriptor connDesc ) : System

Construct the layer. Should typically be called only by the appropriate ConnectionDescriptor.

SequenceExists ( string name ) : bool

Returns whether a sequence with this name exists or not.

StoreHouseMissing ( ) : bool

Returns true if you need to call "CreateStoreHouse" before storing any data. This method is "Missing" not "Exists" because implementations that do not use a store house (I.E. single-file-based data access layers) can return "false" from this method without breaking either a user's app or the spirit of the method. Store house typically corresponds to "database". For SQLite, this merely verifies the file exists, not that you have any particular security permissions or even that it is a valid SQLite database.

StoreRoomMissing ( ClassMapping mapping ) : bool

Returns true if you need to call "CreateStoreRoom" before storing any data. This method is "Missing" not "Exists" because implementations that do not use a store room can return "false" from this method without breaking either a user's app or the spirit of the method. Store room typically corresponds to "table".

Защищенные методы

Метод Описание
GetAutoType ( Type baseType ) : string

Returns the DDL for the type of an automatically incrementing column. Some databases only store autonums in one col type so baseType may be ignored.

GetByteArrayType ( ) : string

Returns the SQL type used to store a byte array in the DB.

GetLongType ( ) : string

Returns the SQL type used to store a long in the DB.

Описание методов

CreateStoreHouse() публичный Метод

Creates the store house specified in the connection descriptor. If this data source doesn't use a store house, this method should be a no-op. If this data source DOES use store houses, but support for adding them is not implemented yet, this should throw a NotImplementedException. Store house typically corresponds to "database". For SQLite this creates a blank database file (no tables).
public CreateStoreHouse ( ) : void
Результат void

DeleteStoreHouse() публичный Метод

Deletes the store house specified in the connection descriptor. If this data source doesn't use a store house, this method should be a no-op. If this data source DOES use store houses, but support for dropping them is not implemented yet, this should throw a NotImplementedException. Store house typically corresponds to "database". If there is no store house with the given name, this should be a no-op. For SQLite, this just deletes the database file.
public DeleteStoreHouse ( ) : void
Результат void

GetAutoType() защищенный Метод

Returns the DDL for the type of an automatically incrementing column. Some databases only store autonums in one col type so baseType may be ignored.
protected GetAutoType ( Type baseType ) : string
baseType System.Type The data type of the column (nominally).
Результат string

GetByteArrayType() защищенный Метод

Returns the SQL type used to store a byte array in the DB.
protected GetByteArrayType ( ) : string
Результат string

GetLongType() защищенный Метод

Returns the SQL type used to store a long in the DB.
protected GetLongType ( ) : string
Результат string

SQLiteDaLayer() публичный Метод

Construct the layer. Should typically be called only by the appropriate ConnectionDescriptor.
public SQLiteDaLayer ( SQLiteDescriptor connDesc ) : System
connDesc SQLiteDescriptor Connection to the Firebird DB we'll be using.
Результат System

SequenceExists() публичный Метод

Returns whether a sequence with this name exists or not.
public SequenceExists ( string name ) : bool
name string Name of the sequence to check for.
Результат bool

StoreHouseMissing() публичный Метод

Returns true if you need to call "CreateStoreHouse" before storing any data. This method is "Missing" not "Exists" because implementations that do not use a store house (I.E. single-file-based data access layers) can return "false" from this method without breaking either a user's app or the spirit of the method. Store house typically corresponds to "database". For SQLite, this merely verifies the file exists, not that you have any particular security permissions or even that it is a valid SQLite database.
public StoreHouseMissing ( ) : bool
Результат bool

StoreRoomMissing() публичный Метод

Returns true if you need to call "CreateStoreRoom" before storing any data. This method is "Missing" not "Exists" because implementations that do not use a store room can return "false" from this method without breaking either a user's app or the spirit of the method. Store room typically corresponds to "table".
public StoreRoomMissing ( ClassMapping mapping ) : bool
mapping ClassMapping
Результат bool