Метод | Описание | |
---|---|---|
Count ( |
Returns the number of records of the specified type in the database
|
|
Count ( |
Returns the number of records of the specified type in the database
|
|
Create ( object instance ) : void |
Creates (Saves) a new instance to the database.
|
|
CreateAndFlush ( object instance ) : void |
Creates (Saves) a new instance to the database and flushes the session.
|
|
Delete ( object instance ) : void |
Deletes the instance from the database.
|
|
DeleteAll ( |
Deletes all targetType objects, based on the primary keys supplied on pkValues.
|
|
DeleteAll ( |
Deletes all entities of the specified type (and their inheritors)
|
|
DeleteAll ( |
Deletes all entities of specified type that match the HQL where clause
|
|
DeleteAndFlush ( object instance ) : void |
Deletes the instance from the database and flushes the session.
|
|
EnumerateQuery ( IActiveRecordQuery q ) : IEnumerable |
Enumerates the query. Note: Only use if you expect most of the values to be on the second level cache
|
|
Execute ( |
Invokes the specified delegate passing a valid NHibernate session. Used for custom NHibernate queries.
|
|
ExecuteQuery ( IActiveRecordQuery q ) : object |
Executes the query
|
|
Exists ( |
Check if there is any records in the db for the target type
|
|
Exists ( |
Check if any instance matching the criteria exists in the database.
|
|
Exists ( |
Check if the id exists in the database.
|
|
Exists ( |
Check if there is any records in the db for the target type
|
|
FindAll ( |
Returns all instances found for the specified type.
|
|
FindAll ( |
Returns all instances found for the specified type according to the criteria
|
|
FindAll ( |
Returns all instances found for the specified type using sort orders and criterias.
|
|
FindAllByProperty ( |
Finds records based on a property value - automatically converts null values to IS NULL style queries.
|
|
FindAllByProperty ( |
Finds records based on a property value - automatically converts null values to IS NULL style queries.
|
|
FindByPrimaryKey ( |
Finds an object instance by its primary key.
|
|
FindByPrimaryKey ( |
Finds an object instance by its primary key.
|
|
FindFirst ( |
Searches and returns the first row.
|
|
FindFirst ( |
Searches and returns the first row.
|
|
FindFirst ( |
Searches and returns the first row.
|
|
FindOne ( |
Searches and returns the a row. If more than one is found, throws ActiveRecordException
|
|
GetSessionFactoryHolder ( ) : ISessionFactoryHolder |
Testing hock only.
|
|
Refresh ( object instance ) : void |
Refresh the instance from the database.
|
|
Replicate ( object instance, NHibernate.ReplicationMode replicationMode ) : void |
From NHibernate documentation: Persist all reachable transient objects, reusing the current identifier values. Note that this will not trigger the Interceptor of the Session.
|
|
Save ( object instance ) : void |
Saves the instance to the database
|
|
SaveAndFlush ( object instance ) : void |
Saves the instance to the database and flushes the session. If the primary key is unitialized it creates the instance on the database. Otherwise it updates it. If the primary key is assigned, then you must invoke Create(object) or Update(object) instead.
|
|
SaveCopy ( object instance ) : object |
Saves a copy of instance to the database
|
|
SaveCopyAndFlush ( object instance ) : void |
Saves a copy of the instance to the database and flushes the session. If the primary key is unitialized it creates the instance on the database. Otherwise it updates it. If the primary key is assigned, then you must invoke Create(object) or Update(object) instead.
|
|
SlicedFindAll ( |
Returns a portion of the query results (sliced)
|
|
SlicedFindAll ( |
Returns a portion of the query results (sliced)
|
|
SlicedFindAll ( |
Returns a portion of the query results (sliced)
|
|
SlicedFindAll ( |
Returns a portion of the query results (sliced)
|
|
Update ( object instance ) : void |
Persists the modification on the instance state to the database.
|
|
UpdateAndFlush ( object instance ) : void |
Persists the modification on the instance state to the database and flushes the session.
|
Метод | Описание | |
---|---|---|
Count ( |
Returns the number of records of the specified type in the database
|
|
FindOne ( |
Searches and returns a row. If more than one is found, throws ActiveRecordException
|
protected static Count ( |
||
targetType | Type of the target. | |
Результат | int |
public static Count ( |
||
targetType | The target type. | |
detachedCriteria | DetachedCriteria | The criteria expression |
Результат | int |
public static Count ( |
||
targetType | Type of the target. | |
filter | string | A sql where string i.e. Person=? and DOB > ? |
Результат | int |
public static Create ( object instance ) : void | ||
instance | object | The ActiveRecord instance to be deleted |
Результат | void |
public static CreateAndFlush ( object instance ) : void | ||
instance | object | The ActiveRecord instance to be created on the database |
Результат | void |
public static Delete ( object instance ) : void | ||
instance | object | The ActiveRecord instance to be deleted |
Результат | void |
public static DeleteAll ( |
||
targetType | The target ActiveRecord type | |
pkValues | IEnumerable | A list of primary keys |
Результат | int |
public static DeleteAll ( |
||
type | The type. | |
Результат | void |
public static DeleteAll ( |
||
type | The type. | |
where | string | The where. |
Результат | void |
public static DeleteAndFlush ( object instance ) : void | ||
instance | object | The ActiveRecord instance to be deleted |
Результат | void |
public static EnumerateQuery ( IActiveRecordQuery q ) : IEnumerable | ||
q | IActiveRecordQuery | The query |
Результат | IEnumerable |
public static Execute ( |
||
targetType | The target ActiveRecordType | |
call | NHibernateDelegate | The delegate instance |
instance | object | The ActiveRecord instance |
Результат | object |
public static ExecuteQuery ( IActiveRecordQuery q ) : object | ||
q | IActiveRecordQuery | The query |
Результат | object |
public static Exists ( |
||
targetType | Type of the target. | |
Результат | bool |
public static Exists ( |
||
targetType | The target type. | |
detachedCriteria | DetachedCriteria | The criteria expression |
Результат | bool |
public static Exists ( |
||
targetType | Type of the target. | |
id | object | The id to check on |
Результат | bool |
public static Exists ( |
||
targetType | Type of the target. | |
filter | string | A sql where string i.e. Person=? and DOB > ? |
Результат | bool |
public static FindAll ( |
||
targetType | ||
Результат |
public static FindAll ( |
||
targetType | ||
detachedCriteria | DetachedCriteria | |
Результат |
public static FindAll ( |
||
targetType | ||
orders | NHibernate.Criterion.Order | |
Результат |
public static FindAllByProperty ( |
||
targetType | The target type | |
orderByColumn | String | The column name to be ordered ASC |
property | String | A property name (not a column name) |
value | object | The value to be equals to |
Результат |
public static FindAllByProperty ( |
||
targetType | The target type | |
property | String | A property name (not a column name) |
value | object | The value to be equals to |
Результат |
public static FindByPrimaryKey ( |
||
targetType | The AR subclass type | |
id | object | ID value |
Результат | object |
public static FindByPrimaryKey ( |
||
targetType | The AR subclass type | |
id | object | ID value |
throwOnNotFound | bool | |
Результат | object |
public static FindFirst ( |
||
targetType | The target type | |
Результат | object |
public static FindFirst ( |
||
targetType | The target type. | |
detachedCriteria | DetachedCriteria | The criteria. |
Результат | object |
public static FindFirst ( |
||
targetType | The target type | |
orders | NHibernate.Criterion.Order | The sort order - used to determine which record is the first one |
Результат | object |
public static FindOne ( |
||
targetType | The target type | |
Результат | object |
protected static FindOne ( |
||
targetType | The target type | |
criteria | DetachedCriteria | The criteria |
Результат | object |
public static GetSessionFactoryHolder ( ) : ISessionFactoryHolder | ||
Результат | ISessionFactoryHolder |
public static Refresh ( object instance ) : void | ||
instance | object | The ActiveRecord instance to be reloaded |
Результат | void |
public static Replicate ( object instance, NHibernate.ReplicationMode replicationMode ) : void | ||
instance | object | The instance. |
replicationMode | NHibernate.ReplicationMode | The replication mode. |
Результат | void |
public static Save ( object instance ) : void | ||
instance | object | The ActiveRecord instance to be deleted |
Результат | void |
public static SaveAndFlush ( object instance ) : void | ||
instance | object | The ActiveRecord instance to be saved |
Результат | void |
public static SaveCopy ( object instance ) : object | ||
instance | object | The transient instance to be copied |
Результат | object |
public static SaveCopyAndFlush ( object instance ) : void | ||
instance | object | The transient instance to be copied |
Результат | void |
public static SlicedFindAll ( |
||
targetType | ||
firstResult | int | |
maxresults | int | |
Результат |
public static SlicedFindAll ( |
||
targetType | ||
firstResult | int | |
maxResults | int | |
criteria | DetachedCriteria | |
Результат |
public static SlicedFindAll ( |
||
targetType | ||
firstResult | int | |
maxresults | int | |
orders | NHibernate.Criterion.Order | |
Результат |
public static SlicedFindAll ( |
||
targetType | ||
firstResult | int | |
maxResults | int | |
orders | NHibernate.Criterion.Order | |
criteria | DetachedCriteria | |
Результат |
public static Update ( object instance ) : void | ||
instance | object | The ActiveRecord instance to be deleted |
Результат | void |
public static UpdateAndFlush ( object instance ) : void | ||
instance | object | The ActiveRecord instance to be updated on the database |
Результат | void |