TemplateFilterUtils
Assembly: ServiceStack.Common.dll
View Source
Declaration
public static class TemplateFilterUtils
Methods
AssertOptions(ScriptScopeContext, String, Object)
View Source
Declaration
public static Dictionary<string, object> AssertOptions(this ScriptScopeContext scope, string filterName, object scopedParams)
Returns
System.Collections.Generic.Dictionary<System.String,System.Object>
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.String | filterName |
System.Object | scopedParams |
AssertOptions(Object, String)
View Source
Declaration
public static Dictionary<string, object> AssertOptions(this object scopedParams, string filterName)
Returns
System.Collections.Generic.Dictionary<System.String,System.Object>
Parameters
Type | Name |
---|---|
System.Object | scopedParams |
System.String | filterName |
AssertNoCircularDeps(Object)
View Source
Declaration
public static object AssertNoCircularDeps(this object value)
Returns
System.Object
Parameters
Type | Name |
---|---|
System.Object | value |
AssertEnumerable(Object, String)
View Source
Declaration
public static IEnumerable<object> AssertEnumerable(this object items, string filterName)
Returns
System.Collections.Generic.IEnumerable<System.Object>
Parameters
Type | Name |
---|---|
System.Object | items |
System.String | filterName |
AssertExpression(ScriptScopeContext, String, Object)
View Source
Declaration
public static string AssertExpression(this ScriptScopeContext scope, string filterName, object expression)
Returns
System.String
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.String | filterName |
System.Object | expression |
AssertExpression(ScriptScopeContext, String, Object, Object, out String)
View Source
Declaration
public static JsToken AssertExpression(this ScriptScopeContext scope, string filterName, object expression, object scopeOptions, out string itemBinding)
Returns
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.String | filterName |
System.Object | expression |
System.Object | scopeOptions |
System.String | itemBinding |
GetParamsWithItemBinding(ScriptScopeContext, String, Object, out String)
View Source
Declaration
public static Dictionary<string, object> GetParamsWithItemBinding(this ScriptScopeContext scope, string filterName, object scopedParams, out string itemBinding)
Returns
System.Collections.Generic.Dictionary<System.String,System.Object>
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.String | filterName |
System.Object | scopedParams |
System.String | itemBinding |
GetParamsWithItemBinding(ScriptScopeContext, String, SharpPage, Object, out String)
View Source
Declaration
public static Dictionary<string, object> GetParamsWithItemBinding(this ScriptScopeContext scope, string filterName, SharpPage page, object scopedParams, out string itemBinding)
Returns
System.Collections.Generic.Dictionary<System.String,System.Object>
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.String | filterName |
ServiceStack.Script.SharpPage | page |
System.Object | scopedParams |
System.String | itemBinding |
GetParamsWithItemBindingOnly(ScriptScopeContext, String, SharpPage, Object, out String)
View Source
Declaration
public static Dictionary<string, object> GetParamsWithItemBindingOnly(this ScriptScopeContext scope, string filterName, SharpPage page, object scopedParams, out string itemBinding)
Returns
System.Collections.Generic.Dictionary<System.String,System.Object>
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.String | filterName |
ServiceStack.Script.SharpPage | page |
System.Object | scopedParams |
System.String | itemBinding |
AddItemToScope(ScriptScopeContext, String, Object, Int32)
View Source
Declaration
public static ScriptScopeContext AddItemToScope(this ScriptScopeContext scope, string itemBinding, object item, int index)
Returns
ServiceStack.Script.ScriptScopeContext
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.String | itemBinding |
System.Object | item |
System.Int32 | index |
AddItemToScope(ScriptScopeContext, String, Object)
View Source
Declaration
public static ScriptScopeContext AddItemToScope(this ScriptScopeContext scope, string itemBinding, object item)
Returns
ServiceStack.Script.ScriptScopeContext
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.String | itemBinding |
System.Object | item |
GetValueOrEvaluateBinding<T>(ScriptScopeContext, Object)
View Source
Declaration
public static T GetValueOrEvaluateBinding<T>(this ScriptScopeContext scope, object valueOrBinding)
Returns
<T>
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.Object | valueOrBinding |
Type Parameters
T
GetValueOrEvaluateBinding(ScriptScopeContext, Object, Type)
View Source
Declaration
public static object GetValueOrEvaluateBinding(this ScriptScopeContext scope, object valueOrBinding, Type returnType)
Returns
System.Object
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.Object | valueOrBinding |
System.Type | returnType |
TryGetPage(ScriptScopeContext, String, out SharpPage, out SharpCodePage)
View Source
Declaration
public static bool TryGetPage(this ScriptScopeContext scope, string virtualPath, out SharpPage page, out SharpCodePage codePage)
Returns
System.Boolean
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.String | virtualPath |
ServiceStack.Script.SharpPage | page |
ServiceStack.Script.SharpCodePage | codePage |
CreateNewContext(ScriptScopeContext, Dictionary<String, Object>)
View Source
Declaration
public static ScriptContext CreateNewContext(this ScriptScopeContext scope, Dictionary<string, object> args)
Returns
ServiceStack.Script.ScriptContext
Parameters
Type | Name |
---|---|
ServiceStack.Script.ScriptScopeContext | scope |
System.Collections.Generic.Dictionary<System.String,System.Object> | args |