Example usage for org.apache.commons.collections4.map ListOrderedMap lastKey

List of usage examples for org.apache.commons.collections4.map ListOrderedMap lastKey

Introduction

In this page you can find the example usage for org.apache.commons.collections4.map ListOrderedMap lastKey.

Prototype

public K lastKey() 

Source Link

Document

Gets the last key in this map by insert order.

Usage

From source file:org.apache.ofbiz.entity.transaction.TransactionUtil.java

/**
* Remove the stamp from stack (when resuming)
*//*  ww w  .jav a  2 s  .  c  o  m*/
private static void popTransactionStartStamp() {
    ListOrderedMap map = (ListOrderedMap) suspendedTxStartStamps.get();
    if (map.size() > 0) {
        transactionStartStamp.set((Timestamp) map.remove(map.lastKey()));
    } else {
        Debug.logError("Error in transaction handling - no saved start stamp found - using NOW.", module);
        transactionStartStamp.set(UtilDateTime.nowTimestamp());
    }
}