Package com.azure.cosmos.models
Class CosmosBatchOperationResult
java.lang.Object
com.azure.cosmos.models.CosmosBatchOperationResult
Represents a result for a specific operation that was part of a
CosmosBatch
request.-
Method Summary
Modifier and TypeMethodDescriptiongetETag()
Gets the entity tag associated with the current item.<T> T
Gets the item associated with the current result.Gets the original operation for this result.double
Gets the request charge as request units (RU) consumed by the current operation.Gets retry after.int
Gets the HTTP status code associated with the current result.int
Gets sub status code associated with the current result.boolean
Gets a value indicating whether the current operation completed successfully.
-
Method Details
-
getETag
Gets the entity tag associated with the current item. ETags are used for concurrency checking when updating resources.- Returns:
- Entity tag associated with the current item.
-
getRequestCharge
public double getRequestCharge()Gets the request charge as request units (RU) consumed by the current operation.For more information about the RU and factors that can impact the effective charges please visit Request Units in Azure Cosmos DB
- Returns:
- the request charge.
-
getItem
Gets the item associated with the current result.- Type Parameters:
T
- the type parameter- Parameters:
type
- class type for which deserialization is needed.- Returns:
- item associated with the current result.
-
getRetryAfterDuration
Gets retry after.- Returns:
- the retry after
-
getSubStatusCode
public int getSubStatusCode()Gets sub status code associated with the current result.- Returns:
- the sub status code
-
isSuccessStatusCode
public boolean isSuccessStatusCode()Gets a value indicating whether the current operation completed successfully.- Returns:
true
if the current operation completed successfully;false
otherwise.
-
getStatusCode
public int getStatusCode()Gets the HTTP status code associated with the current result.- Returns:
- the status code.
-
getOperation
Gets the original operation for this result.- Returns:
- the CosmosItemOperation.
-