AutoQueryDataExtensions
Assembly: ServiceStack.dll
View Source
Declaration
public static class AutoQueryDataExtensions
Methods
ToField(QueryDataFieldAttribute, PropertyInfo, AutoQueryDataFeature)
View Source
Declaration
public static QueryDataField ToField(this QueryDataFieldAttribute attr, PropertyInfo pi, AutoQueryDataFeature feature)
Returns
Parameters
Type | Name |
---|---|
ServiceStack.QueryDataFieldAttribute | attr |
System.Reflection.PropertyInfo | pi |
ServiceStack.AutoQueryDataFeature | feature |
CreateQuery<From>(IAutoQueryData, IQueryData<From>, IRequest, IQueryDataSource)
View Source
Declaration
public static DataQuery<From> CreateQuery<From>(this IAutoQueryData autoQuery, IQueryData<From> model, IRequest request, IQueryDataSource db = null)
Returns
Parameters
Type | Name |
---|---|
ServiceStack.IAutoQueryData | autoQuery |
ServiceStack.IQueryData<From> | model |
ServiceStack.Web.IRequest | request |
ServiceStack.IQueryDataSource | db |
Type Parameters
From
CreateQuery<From, Into>(IAutoQueryData, IQueryData<From, Into>, IRequest, IQueryDataSource)
View Source
Declaration
public static DataQuery<From> CreateQuery<From, Into>(this IAutoQueryData autoQuery, IQueryData<From, Into> model, IRequest request, IQueryDataSource db = null)
Returns
Parameters
Type | Name |
---|---|
ServiceStack.IAutoQueryData | autoQuery |
ServiceStack.IQueryData<From> | model |
ServiceStack.Web.IRequest | request |
ServiceStack.IQueryDataSource | db |
Type Parameters
From
Into
MemorySource<T>(QueryDataContext, IEnumerable<T>)
View Source
Declaration
public static IQueryDataSource<T> MemorySource<T>(this QueryDataContext ctx, IEnumerable<T> source)
Returns
ServiceStack.IQueryDataSource<T>
Parameters
Type | Name |
---|---|
ServiceStack.QueryDataContext | ctx |
System.Collections.Generic.IEnumerable<<T>> | source |
Type Parameters
T
MemorySource<T>(QueryDataContext, Func<IEnumerable<T>>, ICacheClient, Nullable<TimeSpan>, String)
View Source
Declaration
public static IQueryDataSource<T> MemorySource<T>(this QueryDataContext ctx, Func<IEnumerable<T>> sourceFn, ICacheClient cache, TimeSpan? expiresIn = null, string cacheKey = null)
Returns
ServiceStack.IQueryDataSource<T>
Parameters
Type | Name |
---|---|
ServiceStack.QueryDataContext | ctx |
System.Func<System.Collections.Generic.IEnumerable<<T>>> | sourceFn |
ServiceStack.Caching.ICacheClient | cache |
System.Nullable<System.TimeSpan> | expiresIn |
System.String | cacheKey |
Type Parameters
T
And<T>(IDataQuery, Expression<Func<T, Object>>, QueryCondition, Object)
View Source
Declaration
public static void And<T>(this IDataQuery q, Expression<Func<T, object>> fieldExpr, QueryCondition condition, object value)
Parameters
Type | Name |
---|---|
ServiceStack.IDataQuery | q |
System.Linq.Expressions.Expression<System.Func<<T>,System.Object>> | fieldExpr |
ServiceStack.QueryCondition | condition |
System.Object | value |
Type Parameters
T
Or<T>(IDataQuery, Expression<Func<T, Object>>, QueryCondition, Object)
View Source
Declaration
public static void Or<T>(this IDataQuery q, Expression<Func<T, object>> fieldExpr, QueryCondition condition, object value)
Parameters
Type | Name |
---|---|
ServiceStack.IDataQuery | q |
System.Linq.Expressions.Expression<System.Func<<T>,System.Object>> | fieldExpr |
ServiceStack.QueryCondition | condition |
System.Object | value |
Type Parameters
T
WithAudit<T>(T, IRequest, Nullable<DateTime>)
View Source
Declaration
public static T WithAudit<T>(this T row, IRequest req, DateTime? date = null)
where T : AuditBase
Returns
<T>
Parameters
Type | Name |
---|---|
<T> | row |
ServiceStack.Web.IRequest | req |
System.Nullable<System.DateTime> | date |
Type Parameters
T
WithAudit<T>(T, String, Nullable<DateTime>)
View Source
Declaration
public static T WithAudit<T>(this T row, string by, DateTime? date = null)
where T : AuditBase
Returns
<T>
Parameters
Type | Name |
---|---|
<T> | row |
System.String | by |
System.Nullable<System.DateTime> | date |
Type Parameters
T