public String toString() { return "[" + this.priority + ": " + this.event.toString() + "]"; } }
/** * Returns the event info for the given key. * * @param event event. * @return the event info for the given key. */ public EventInfo get(Event event) { return events.get(event.toString()); }
/** * Maps an event to the corresponding event info. * * @param key key with which the specified value is to be associated * @param value value to be associated with the specified key * @return the previous value associated with <tt>key</tt>, or <tt>null</tt> if there was no * mapping for <tt>key</tt>. (A <tt>null</tt> return can also indicate that the map * previously associated <tt>null</tt> with <tt>key</tt>.) */ public EventInfo put(Event key, EventInfo value) { EventInfo ei = events.put(key.toString(), value); if (maxElapsedEventInfo == null || maxElapsedEventInfo.getElapsed() < value.getElapsed()) { maxElapsedEventInfo = value; } return ei; }