C# Класс Azavea.Open.DAO.Memory.MemoryDescriptor

Describes a connection to "memory". This is mostly intended as a test implementation, the data source is just a structure in memory, but it is possible this will have some practical applications as well. Two connections using the same uid will hit the same in-memory collection of objects.
Наследование: ConnectionDescriptor
Показать файл Открыть проект

Открытые свойства

Свойство Тип Описание
Uid string

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

Метод Описание
CreateDataAccessLayer ( ) : IDaLayer

Returns the appropriate data access layer for this connection.

MemoryDescriptor ( Config config, string component, ConnectionInfoDecryptionDelegate decryptionDelegate ) : Azavea.Open.Common

Populates the descriptor's values from a config file.

MemoryDescriptor ( string uid ) : Azavea.Open.Common

Instantiate an in-memory datastore connection.

ToCleanString ( ) : string

This method is similar to ToString, except it will not contain any "sensitive" information, I.E. passwords. This method is intended to be used for logging or error handling, where we do not want to display passwords to (potentially) just anyone, but we do want to indicate what DB connection we were using.

ToCompleteString ( ) : string

Since we often need to represent database connection info as strings, child classes must implement ToCompleteString() such that this.Equals(that) and this.ToCompleteString().Equals(that.ToCompleteString()) will behave the same.

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

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

Returns the appropriate data access layer for this connection.
public CreateDataAccessLayer ( ) : IDaLayer
Результат IDaLayer

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

Populates the descriptor's values from a config file.
public MemoryDescriptor ( Config config, string component, ConnectionInfoDecryptionDelegate decryptionDelegate ) : Azavea.Open.Common
config Azavea.Open.Common.Config Config to get params from.
component string Section of the config XML to look in for db params.
decryptionDelegate ConnectionInfoDecryptionDelegate Delegate to call to decrypt password fields. /// May be null if passwords are in plain text.
Результат Azavea.Open.Common

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

Instantiate an in-memory datastore connection.
public MemoryDescriptor ( string uid ) : Azavea.Open.Common
uid string The ID of the in-memory store this descriptor connects to.
Результат Azavea.Open.Common

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

This method is similar to ToString, except it will not contain any "sensitive" information, I.E. passwords. This method is intended to be used for logging or error handling, where we do not want to display passwords to (potentially) just anyone, but we do want to indicate what DB connection we were using.
public ToCleanString ( ) : string
Результат string

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

Since we often need to represent database connection info as strings, child classes must implement ToCompleteString() such that this.Equals(that) and this.ToCompleteString().Equals(that.ToCompleteString()) will behave the same.
public ToCompleteString ( ) : string
Результат string

Описание свойств

Uid публичное свойство

The ID of the in-memory store this descriptor connects to.
public string Uid
Результат string