C# Class Azavea.Open.DAO.Unqueryable.UnqueryableDaLayer

A base class for data access layers that have no native query support and instead have to manually implement querying.
Inheritance: AbstractDaLayer
Datei anzeigen Open project: azavea/net-dao Class Usage Examples

Protected Properties

Property Type Description
_queryCache Common.Caching.ClearingCache

Public Methods

Method Description
CreateQuery ( ClassMapping mapping, DaoCriteria crit ) : IDaQuery

Builds the query based on a serializable criteria. The Query object is particular to the implementation, but may contain things like the parameters parsed out, or whatever makes sense to this FastDaoLayer. You can think of this method as a method to convert from the generic DaoCriteria into the specific details necessary for querying.

DisposeOfQuery ( IDaQuery query ) : void

Should be called when you're done with the query. Allows us to cache the objects for reuse.

Protected Methods

Method Description
UnqueryableDaLayer ( IConnectionDescriptor connDesc, bool supportsNumRecords ) : Azavea.Open.DAO.Criteria

Instantiates the data access layer with the connection descriptor for the data source.

Method Details

CreateQuery() public method

Builds the query based on a serializable criteria. The Query object is particular to the implementation, but may contain things like the parameters parsed out, or whatever makes sense to this FastDaoLayer. You can think of this method as a method to convert from the generic DaoCriteria into the specific details necessary for querying.
public CreateQuery ( ClassMapping mapping, DaoCriteria crit ) : IDaQuery
mapping ClassMapping The mapping of the table for which to build the query string.
crit Azavea.Open.DAO.Criteria.DaoCriteria The criteria to use to find the desired objects.
return IDaQuery

DisposeOfQuery() public method

Should be called when you're done with the query. Allows us to cache the objects for reuse.
public DisposeOfQuery ( IDaQuery query ) : void
query IDaQuery Query you're done using.
return void

UnqueryableDaLayer() protected method

Instantiates the data access layer with the connection descriptor for the data source.
protected UnqueryableDaLayer ( IConnectionDescriptor connDesc, bool supportsNumRecords ) : Azavea.Open.DAO.Criteria
connDesc IConnectionDescriptor The connection descriptor that is being used by this FastDaoLayer.
supportsNumRecords bool If true, methods that return numbers of records affected will be /// returning accurate numbers. If false, they will probably return /// FastDAO.UNKNOWN_NUM_ROWS.
return Azavea.Open.DAO.Criteria

Property Details

_queryCache protected_oe property

Cache used to store the queries for reuse.
protected Common.Caching.ClearingCache _queryCache
return Common.Caching.ClearingCache