Class RequestOptions
The default cosmos request options
public class RequestOptions
- Inheritance
-
RequestOptions
- Derived
- Inherited Members
- Extension Methods
Constructors
RequestOptions()
public RequestOptions()
Properties
AddRequestHeaders
Gets or sets a delegate which injects/appends a custom header in the request.
public Action<Headers> AddRequestHeaders { get; set; }
Property Value
IfMatchEtag
Gets or sets the If-Match (ETag) associated with the request in the Azure Cosmos DB service.
public string IfMatchEtag { get; set; }
Property Value
Remarks
Most commonly used with the Delete* and Replace* methods of Container such as ReplaceItemAsync<T>(T, string, PartitionKey?, ItemRequestOptions, CancellationToken) but can be used with other methods like ReadItemAsync<T>(string, PartitionKey, ItemRequestOptions, CancellationToken) for caching scenarios.
IfNoneMatchEtag
Gets or sets the If-None-Match (ETag) associated with the request in the Azure Cosmos DB service.
public string IfNoneMatchEtag { get; set; }
Property Value
Remarks
Most commonly used to detect changes to the resource
Properties
Application opted Cosmos request context that flow through with the RequestMessage. Context will be available through handlers.
public IReadOnlyDictionary<string, object> Properties { get; set; }
Property Value
Methods
ShallowCopy()
Clone RequestOptions.
public RequestOptions ShallowCopy()
Returns
- RequestOptions
cloned RequestOptions.