Share via


ODataQueryOptions.ApplyTo Method

 

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

Overload List

Name Description
System_CAPS_pubmethod ApplyTo(IQueryable)

Apply the individual query to the given IQueryable in the right order.

System_CAPS_pubmethod ApplyTo(IQueryable, ODataQuerySettings)

Apply the individual query to the given IQueryable in the right order.

System_CAPS_pubmethod ApplyTo(Object, ODataQuerySettings)

Applies the query to the given entity using the given ODataQuerySettings.

See Also

ODataQueryOptions Class
System.Web.Http.OData.Query Namespace

Return to top

ODataQueryOptions.ApplyTo Method (IQueryable)

Apply the individual query to the given IQueryable in the right order.

Syntax

public virtual IQueryable ApplyTo(
    IQueryable query
)
public:
virtual IQueryable^ ApplyTo(
    IQueryable^ query
)
abstract ApplyTo : 
        query:IQueryable -> IQueryable
override ApplyTo : 
        query:IQueryable -> IQueryable
Public Overridable Function ApplyTo (
    query As IQueryable
) As IQueryable

Parameters

Return Value

Type: System.Linq.IQueryable

The new IQueryable after the query has been applied to.

Return to top

ODataQueryOptions.ApplyTo Method (IQueryable, ODataQuerySettings)

Apply the individual query to the given IQueryable in the right order.

Syntax

public virtual IQueryable ApplyTo(
    IQueryable query,
    ODataQuerySettings querySettings
)
public:
virtual IQueryable^ ApplyTo(
    IQueryable^ query,
    ODataQuerySettings^ querySettings
)
abstract ApplyTo : 
        query:IQueryable *
        querySettings:ODataQuerySettings -> IQueryable
override ApplyTo : 
        query:IQueryable *
        querySettings:ODataQuerySettings -> IQueryable
Public Overridable Function ApplyTo (
    query As IQueryable,
    querySettings As ODataQuerySettings
) As IQueryable

Parameters

Return Value

Type: System.Linq.IQueryable

The new IQueryable after the query has been applied to.

Return to top

ODataQueryOptions.ApplyTo Method (Object, ODataQuerySettings)

Applies the query to the given entity using the given ODataQuerySettings.

Syntax

public virtual object ApplyTo(
    object entity,
    ODataQuerySettings querySettings
)
public:
virtual Object^ ApplyTo(
    Object^ entity,
    ODataQuerySettings^ querySettings
)
abstract ApplyTo : 
        entity:Object *
        querySettings:ODataQuerySettings -> Object
override ApplyTo : 
        entity:Object *
        querySettings:ODataQuerySettings -> Object
Public Overridable Function ApplyTo (
    entity As Object,
    querySettings As ODataQuerySettings
) As Object

Parameters

Return Value

Type: System.Object

The new entity after the $select and $expand query has been applied to.

Remarks

Only $select and $expand query options can be applied on single entities. This method throws if the query contains any other query options.

Return to top