Apama 10.3 | Apama Documentation | Connecting Apama Applications to External Components | Working with IAF Plug-ins | Plug-in Support APIs for Java | Using the latency framework | Java latency framework API
Java latency framework API
The Java interface for the latency framework is declared in the header file com.apama.util.TimestampSet class.
The functions of interest are the following.
void addNow(java.lang.Integer index)
Add a new name-time pair to the event.
void addTime(java.lang.Integer index, java.lang.Double theTime)
Add a new index-time pair to the timestamp.
void clear()
Removes all mappings from this map.
boolean containsKey(java.lang.Object index)
Returns true if this map contains the specified key
boolean containsValue(java.lang.Object time)
Returns true if this map maps one or more names to the specified time.
java.util.Set<java.util.Map.Entry<java.lang.Integer, java.lang.Double>> entrySet()
java.lang.Double findTime(java.lang.Integer index)
Search for a named element in the timestamp set and return its time.
java.lang.Double findTimeAndRemove(java.lang.Integer index)
Search for a named element in the timestamp set and return its time.
java.lang.Double get(java.lang.Object index)
Returns the time to which the specified name is mapped, or null if the map contains no mapping for this index.
static double getMicroTime()
Get the current microsecond-accurate relative timestamp.
boolean isEmpty()
Returns true if this map contains no index-time mappings.
java.util.Iterator<java.util.Map.Entry<java.lang.Integer, java.lang.Double>> iterator()
Returns a standard Java Iterator over the contents of the TimestampSet using Map.Entry objects.
java.util.Set<java.lang.Integer> keySet()
java.lang.Double put(java.lang.Integer index, java.lang.Double time)
Adds or replaces the specified (index,time) pair in the underlying map
void putAll(java.util.Map<? extends java.lang.Integer,? extends java.lang.Double> m)
Copies all of the mappings from the specified map to this map These mappings will replace any mappings that this map had for any of the indices currently in the specified map.
java.lang.Double remove(java.lang.Object index)
Removes the mapping for this index from this map if present.
void replace(java.lang.Integer index, java.lang.Double newTime)
Change the time of a named element in the timestamp set.
void replaceWithNow(java.lang.Integer index)
Change the time of a named element in the timestamp set.
int size()
Get the number of elements (name-time pairs) currently stored by the event.
java.lang.String toString()
Return a printable string representation of the timestamp set.
java.util.Collection<java.lang.Double> values()
Returns a collection view of the times contained in this map.

Copyright © 2013-2018 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.