Example usage for com.amazonaws.services.dynamodbv2.model ConsumedCapacity getTable

List of usage examples for com.amazonaws.services.dynamodbv2.model ConsumedCapacity getTable

Introduction

In this page you can find the example usage for com.amazonaws.services.dynamodbv2.model ConsumedCapacity getTable.

Prototype


public Capacity getTable() 

Source Link

Document

The amount of throughput consumed on the table affected by the operation.

Usage

From source file:org.xmlsh.aws.util.AWSDDBCommand.java

License:BSD License

protected void writeConsumedCapacity(ConsumedCapacity consumedCapacity) throws XMLStreamException {
    if (consumedCapacity == null)
        return;/* ww w  .j a  v a 2 s. c o m*/
    startElement("consumed-capacity");
    attribute("total-units", consumedCapacity.getCapacityUnits());
    startElement("table");
    writeCapacity("table-name", consumedCapacity.getTableName(), consumedCapacity.getTable());
    endElement();
    startElement("local-secondary-indexes");
    for (Entry<String, Capacity> ce : consumedCapacity.getLocalSecondaryIndexes().entrySet())
        writeCapacity("index-name", ce.getKey(), ce.getValue());
    endElement();

    startElement("global-secondary-indexes");
    for (Entry<String, Capacity> ce : consumedCapacity.getGlobalSecondaryIndexes().entrySet())
        writeCapacity("index-name", ce.getKey(), ce.getValue());
    endElement();
    endElement();

}