QueryableAttribute Class

This class defines an attribute that can be applied to an action to enable querying using the OData query syntax. To avoid processing unexpected or malicious queries, use the validation settings on QueryableAttribute to validate incoming queries. For more information, visit http://go.microsoft.com/fwlink/?LinkId=279712.

Namespace:  System.Web.Http
Assembly:  System.Web.Http.OData (in System.Web.Http.OData.dll)

[AttributeUsageAttribute(AttributeTargets.Class|AttributeTargets.Method, Inherited = true, 
	AllowMultiple = false)]
public class QueryableAttribute : ActionFilterAttribute

The QueryableAttribute type exposes the following members.

  NameDescription
Public methodQueryableAttributeInitializes a new instance of the QueryableAttribute class.
Top

  NameDescription
Public propertyAllowedArithmeticOperatorsGets or sets a value that represents a list of allowed arithmetic operators including 'add', 'sub', 'mul', 'div', 'mod'.
Public propertyAllowedFunctionsGets or sets a value that represents a list of allowed functions used in the $filter query.
Public propertyAllowedLogicalOperatorsGets or sets a value that represents a list of allowed logical Operators such as 'eq', 'ne', 'gt', 'ge', 'lt', 'le', 'and', 'or', 'not'.
Public propertyAllowedOrderByPropertiesGets or sets a string with comma-separated list of property names. The queryable result can only be ordered by those properties defined in this list.
Public propertyAllowedQueryOptionsGets or sets the query parameters that are allowed in queries.
Public propertyAllowMultiple (Inherited from FilterAttribute.)
Public propertyEnableConstantParameterizationGets or sets a value indicating whether constants should be parameterized. Parameterizing constants would result in better performance with Entity framework.
Public propertyEnsureStableOrderingGets or sets a value indicating whether query composition should alter the original query when necessary to ensure a stable sort order.
Public propertyHandleNullPropagationGets or sets a value indicating how null propagation should be handled during query composition.
Public propertyMaxAnyAllExpressionDepthGets or sets the maximum depth of the Any or All elements nested inside the query.
Public propertyMaxExpansionDepthGets or sets the max expansion depth for the $expand query option.
Public propertyMaxNodeCountGets or sets the maximum number of nodes inside the $filter syntax tree.
Public propertyMaxOrderByNodeCountGets or sets the maximum number of expressions that can be present in the $orderby.
Public propertyMaxSkipGets or sets the max value of $skip that a client can request.
Public propertyMaxTopGets or sets the max value of $top that a client can request.
Public propertyPageSizeGets or sets the maximum number of query results to send back to clients.
Public propertyTypeId (Inherited from Attribute.)
Top

  NameDescription
Public methodApplyQuery(IQueryable, ODataQueryOptions)Applies the query to the given entity based on incoming query from uri and query settings.
Public methodApplyQuery(Object, ODataQueryOptions) Applies the query to the given entity based on incoming query from uri and query settings.
Public methodEquals (Inherited from Attribute.)
Protected methodFinalize (Inherited from Object.)
Public methodGetHashCode (Inherited from Attribute.)
Public methodGetModelGets the EDM model for the given type and request.
Public methodGetType (Inherited from Object.)
Public methodIsDefaultAttribute (Inherited from Attribute.)
Public methodMatch (Inherited from Attribute.)
Protected methodMemberwiseClone (Inherited from Object.)
Public methodOnActionExecutedPerforms the query composition after action is executed. (Overrides ActionFilterAttribute.OnActionExecuted(HttpActionExecutedContext).)
Public methodOnActionExecutedAsync (Inherited from ActionFilterAttribute.)
Public methodOnActionExecuting (Inherited from ActionFilterAttribute.)
Public methodOnActionExecutingAsync (Inherited from ActionFilterAttribute.)
Public methodToString (Inherited from Object.)
Public methodValidateQueryValidates the OData query in the incoming request.
Top

No content here will be updated; please do not add material here.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Show: