Partager via


ODataController.Created Method

 

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

Overload List

Name Description
System_CAPS_protmethod Created<TEntity>(TEntity)

Creates an action result with the specified values that is a response to a POST operation with an entity to an entity set.

System_CAPS_protmethod Created<T>(String, T)

Creates a CreatedNegotiatedContentResult<T> (201 Created) with the specified values.(Inherited from ApiController.)

System_CAPS_protmethod Created<T>(Uri, T)

Creates a CreatedNegotiatedContentResult<T> (201 Created) with the specified values.(Inherited from ApiController.)

See Also

ODataController Class
System.Web.OData Namespace

Return to top

ODataController.Created<TEntity> Method (TEntity)

Creates an action result with the specified values that is a response to a POST operation with an entity to an entity set.

Syntax

protected virtual CreatedODataResult<TEntity> Created<TEntity>(
    TEntity entity
)
protected:
generic<typename TEntity>
virtual CreatedODataResult<TEntity>^ Created(
    TEntity entity
)
abstract Created<'TEntity> : 
        entity:'TEntity -> CreatedODataResult<'TEntity>
override Created<'TEntity> : 
        entity:'TEntity -> CreatedODataResult<'TEntity>
Protected Overridable Function Created(Of TEntity) (
    entity As TEntity
) As CreatedODataResult(Of TEntity)

Parameters

  • entity
    Type: TEntity

    The created entity.

Return Value

Type: System.Web.OData.Results.CreatedODataResult<TEntity>

A CreatedODataResult<T> with the specified values.

Type Parameters

  • TEntity
    The created entity type.

Return to top