Class RepositoryBase<T>
Inheritance
RepositoryBase<T>
Assembly: DotNetNuke.dll
Syntax
public abstract class RepositoryBase<T> : IRepository<T> where T : class
Type Parameters
Constructors
RepositoryBase()
Declaration
protected RepositoryBase()
Properties
CacheArgs
Declaration
protected CacheItemArgs CacheArgs { get; }
Property Value
IsCacheable
Declaration
protected bool IsCacheable { get; }
Property Value
IsScoped
Declaration
protected bool IsScoped { get; }
Property Value
Scope
Declaration
protected string Scope { get; }
Property Value
Methods
CompareTo<TProperty>(TProperty, TProperty)
Declaration
protected int CompareTo<TProperty>(TProperty first, TProperty second)
Parameters
Type |
Name |
Description |
TProperty |
first |
|
TProperty |
second |
|
Returns
Type Parameters
Name |
Description |
TProperty |
|
Delete(string, params object[])
Declaration
public abstract void Delete(string sqlCondition, params object[] args)
Parameters
Delete(T)
Declaration
public void Delete(T item)
Parameters
Type |
Name |
Description |
T |
item |
|
DeleteInternal(T)
Declaration
protected abstract void DeleteInternal(T item)
Parameters
Type |
Name |
Description |
T |
item |
|
Find(int, int, string, params object[])
Declaration
public abstract IPagedList<T> Find(int pageIndex, int pageSize, string sqlCondition, params object[] args)
Parameters
Returns
Find(string, params object[])
Declaration
public abstract IEnumerable<T> Find(string sqlCondition, params object[] args)
Parameters
Returns
Get()
Declaration
public IEnumerable<T> Get()
Returns
GetByIdInternal(object)
Declaration
protected abstract T GetByIdInternal(object id)
Parameters
Type |
Name |
Description |
object |
id |
|
Returns
GetById<TProperty>(TProperty)
Declaration
public T GetById<TProperty>(TProperty id)
Parameters
Type |
Name |
Description |
TProperty |
id |
|
Returns
Type Parameters
Name |
Description |
TProperty |
|
GetById<TProperty, TScopeType>(TProperty, TScopeType)
Declaration
public T GetById<TProperty, TScopeType>(TProperty id, TScopeType scopeValue)
Parameters
Type |
Name |
Description |
TProperty |
id |
|
TScopeType |
scopeValue |
|
Returns
Type Parameters
Name |
Description |
TProperty |
|
TScopeType |
|
GetByScopeInternal(object)
Declaration
protected abstract IEnumerable<T> GetByScopeInternal(object propertyValue)
Parameters
Type |
Name |
Description |
object |
propertyValue |
|
Returns
GetInternal()
Declaration
protected abstract IEnumerable<T> GetInternal()
Returns
GetPage(int, int)
Declaration
public IPagedList<T> GetPage(int pageIndex, int pageSize)
Parameters
Type |
Name |
Description |
int |
pageIndex |
|
int |
pageSize |
|
Returns
GetPageByScopeInternal(object, int, int)
Declaration
protected abstract IPagedList<T> GetPageByScopeInternal(object propertyValue, int pageIndex, int pageSize)
Parameters
Type |
Name |
Description |
object |
propertyValue |
|
int |
pageIndex |
|
int |
pageSize |
|
Returns
GetPageInternal(int, int)
Declaration
protected abstract IPagedList<T> GetPageInternal(int pageIndex, int pageSize)
Parameters
Type |
Name |
Description |
int |
pageIndex |
|
int |
pageSize |
|
Returns
GetPage<TScopeType>(TScopeType, int, int)
Declaration
public IPagedList<T> GetPage<TScopeType>(TScopeType scopeValue, int pageIndex, int pageSize)
Parameters
Type |
Name |
Description |
TScopeType |
scopeValue |
|
int |
pageIndex |
|
int |
pageSize |
|
Returns
Type Parameters
Name |
Description |
TScopeType |
|
GetPrimaryKey<TProperty>(T)
Declaration
protected TProperty GetPrimaryKey<TProperty>(T item)
Parameters
Type |
Name |
Description |
T |
item |
|
Returns
Type |
Description |
TProperty |
|
Type Parameters
Name |
Description |
TProperty |
|
GetPropertyValue<TProperty>(T, string)
Declaration
protected TProperty GetPropertyValue<TProperty>(T item, string propertyName)
Parameters
Type |
Name |
Description |
T |
item |
|
string |
propertyName |
|
Returns
Type |
Description |
TProperty |
|
Type Parameters
Name |
Description |
TProperty |
|
GetScopeValue<TProperty>(T)
Declaration
protected TProperty GetScopeValue<TProperty>(T item)
Parameters
Type |
Name |
Description |
T |
item |
|
Returns
Type |
Description |
TProperty |
|
Type Parameters
Name |
Description |
TProperty |
|
Get<TScopeType>(TScopeType)
Declaration
public IEnumerable<T> Get<TScopeType>(TScopeType scopeValue)
Parameters
Type |
Name |
Description |
TScopeType |
scopeValue |
|
Returns
Type Parameters
Name |
Description |
TScopeType |
|
Initialize(string, int, CacheItemPriority, string)
Declaration
public void Initialize(string cacheKey, int cacheTimeOut = 20, CacheItemPriority cachePriority = CacheItemPriority.Default, string scope = "")
Parameters
Insert(T)
Declaration
public void Insert(T item)
Parameters
Type |
Name |
Description |
T |
item |
|
InsertInternal(T)
Declaration
protected abstract void InsertInternal(T item)
Parameters
Type |
Name |
Description |
T |
item |
|
Update(string, params object[])
Declaration
public abstract void Update(string sqlCondition, params object[] args)
Parameters
Update(T)
Declaration
public void Update(T item)
Parameters
Type |
Name |
Description |
T |
item |
|
UpdateInternal(T)
Declaration
protected abstract void UpdateInternal(T item)
Parameters
Type |
Name |
Description |
T |
item |
|
Implements
Extension Methods