Class UpdatedODataResult<T>
Represents an action result that is a response to a PUT, PATCH, or a MERGE operation on an OData entity.
public class UpdatedODataResult<T> : IHttpActionResult
Type Parameters
T
The entity type.
- Inheritance
-
UpdatedODataResult<T>
- Implements
-
IHttpActionResult
- Inherited Members
Constructors
UpdatedODataResult(T, IContentNegotiator, HttpRequestMessage, IEnumerable<MediaTypeFormatter>)
Initializes a new instance of the UpdatedODataResult<T> class.
public UpdatedODataResult(T entity, IContentNegotiator contentNegotiator, HttpRequestMessage request, IEnumerable<MediaTypeFormatter> formatters)
Parameters
entity
TThe updated entity.
contentNegotiator
IContentNegotiatorThe content negotiator to handle content negotiation.
request
HttpRequestMessageThe request message which led to this result.
formatters
IEnumerable<MediaTypeFormatter>The formatters to use to negotiate and format the content.
UpdatedODataResult(T, ApiController)
Initializes a new instance of the UpdatedODataResult<T> class.
public UpdatedODataResult(T entity, ApiController controller)
Parameters
entity
TThe updated entity.
controller
ApiControllerThe controller from which to obtain the dependencies needed for execution.
Properties
ContentNegotiator
Gets the content negotiator to handle content negotiation.
public IContentNegotiator ContentNegotiator { get; }
Property Value
- IContentNegotiator
Entity
Gets the entity that was updated.
public T Entity { get; }
Property Value
- T
Formatters
Gets the formatters to use to negotiate and format the content.
public IEnumerable<MediaTypeFormatter> Formatters { get; }
Property Value
- IEnumerable<MediaTypeFormatter>
Request
Gets the request message which led to this result.
public HttpRequestMessage Request { get; }
Property Value
Methods
ExecuteAsync(CancellationToken)
public virtual Task<HttpResponseMessage> ExecuteAsync(CancellationToken cancellationToken)
Parameters
cancellationToken
CancellationToken