C# Class Castle.ActiveRecord.Queries.CountQuery

Query the database for a count (using COUNT(*) ) of all the entites of the specified type. Optionally using a where clause; Note: If Criteria are used, this query can not be included in a MultiQuery.
Inheritance: Castle.ActiveRecord.Queries.HqlBasedQuery
Show file Open project: nats/castle-1.0.3-mono Class Usage Examples

Public Methods

Method Description
CountQuery ( Type targetType ) : System

Initializes a new instance of the CountQuery class.

CountQuery ( Type targetType, DetachedCriteria detachedCriteria ) : System

Initializes a new instance of the CountQuery class.

CountQuery ( Type targetType, ICriterion criterias ) : System

Initializes a new instance of the CountQuery class.

CountQuery ( Type targetType, string filter ) : System

Initializes a new instance of the CountQuery class.

Protected Methods

Method Description
InternalExecute ( ISession session ) : object

Executes the query.

Method Details

CountQuery() public method

Initializes a new instance of the CountQuery class.
public CountQuery ( Type targetType ) : System
targetType System.Type The target type.
return System

CountQuery() public method

Initializes a new instance of the CountQuery class.
public CountQuery ( Type targetType, DetachedCriteria detachedCriteria ) : System
targetType System.Type The target type.
detachedCriteria DetachedCriteria Criteria applied to the query
return System

CountQuery() public method

Initializes a new instance of the CountQuery class.
public CountQuery ( Type targetType, ICriterion criterias ) : System
targetType System.Type The target type.
criterias ICriterion Criteria applied to the query
return System

CountQuery() public method

Initializes a new instance of the CountQuery class.
public CountQuery ( Type targetType, string filter ) : System
targetType System.Type The target type.
filter string The filter.
return System

InternalExecute() protected method

Executes the query.
protected InternalExecute ( ISession session ) : object
session ISession The NHibernate's
return object