|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.util.AbstractCollection | +--java.util.AbstractList | +--java.util.Vector | +--atropos.util.OrderedList | +--atropos.lp.AvnmpQueue
This class implements a queue for the logical process receive and send queues.
This research is funded by DARPA/ITO Contract Number: F30602-98-C-0230 supported by the Air Force Research Laboratory/IF.
Field Summary | |
protected java.lang.String |
QueueName
Is this a send or receive queue ? |
Fields inherited from class java.util.Vector |
capacityIncrement, elementCount, elementData |
Fields inherited from class java.util.AbstractList |
modCount |
Constructor Summary | |
AvnmpQueue()
Create an empty queue. |
|
AvnmpQueue(java.lang.String name)
Create an empty queue with the input name. |
Method Summary | |
boolean |
add(java.lang.Object sa)
Add to the sorted table. |
void |
addMessage(AvnmpPacket ap,
AvnmpLP mylp)
Add a message to this queue. |
AvnmpQueue |
append(AvnmpQueue q,
AvnmpLP mylp)
Append the elements of another queue to this one. |
protected void |
cancel(AvnmpPacket cp,
AvnmpLP mylp)
Check for cancellation of an anti-message. |
int |
compare(java.lang.Object o1,
java.lang.Object o2)
This is required to keep the packets sorted by receive time. |
void |
deleteMessage(AvnmpPacket ap)
Delete a message from this queue. |
AvnmpPacket |
getClosestTime(long st,
AvnmpLP mylp)
Return the packet from this queue whose receive time is closest to the input time. |
AvnmpPacket |
getGreaterOrEqualRecTime(long rt)
|
AvnmpPacket |
getGreaterOrEqualSndTime(long st)
|
AvnmpPacket |
getGreaterRecTime(long rt)
|
AvnmpPacket |
getGreaterSndTime(long st)
|
AvnmpPacket |
getLessOrEqualRecTime(long rt)
|
AvnmpPacket |
getLessOrEqualSndTime(long st)
|
AvnmpPacket |
getLessRecTime(long rt)
|
AvnmpPacket |
getLessSndTime(long st)
|
AvnmpPacket |
getMessage(byte a,
java.lang.String Src,
long rt,
java.lang.String Dst,
long st)
Return a pointer to the message in this queue which matches the input parameters. |
AvnmpPacket |
getReal()
|
AvnmpPacket |
getVirtual()
|
double |
numReal(long t)
Return the number of real messages between two times. |
double |
numVirtual(long t)
Return the number of virtual messages between two times. |
void |
plotQueue(AvnmpLP mylp)
Generate a gnuplot data file of the current state of the queue. |
java.lang.String |
QtoString()
Display the contents of this queue. |
int |
queueSize()
Return the size of the queue. |
boolean |
remove(java.lang.Object sa)
Remove a from the sorted table. |
Methods inherited from class atropos.util.OrderedList |
clear, get, remove |
Methods inherited from class java.util.Vector |
add, addAll, addAll, addElement, capacity, clone, contains, containsAll, copyInto, elementAt, elements, ensureCapacity, equals, firstElement, hashCode, indexOf, indexOf, insertElementAt, isEmpty, lastElement, lastIndexOf, lastIndexOf, removeAll, removeAllElements, removeElement, removeElementAt, removeRange, retainAll, set, setElementAt, setSize, size, subList, toArray, toArray, toString, trimToSize |
Methods inherited from class java.util.AbstractList |
iterator, listIterator, listIterator |
Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.List |
iterator, listIterator, listIterator |
Field Detail |
protected java.lang.String QueueName
Constructor Detail |
public AvnmpQueue()
public AvnmpQueue(java.lang.String name)
name
- Queue name.Method Detail |
public boolean add(java.lang.Object sa)
add
in class OrderedList
public boolean remove(java.lang.Object sa)
remove
in class java.util.Vector
public void addMessage(AvnmpPacket ap, AvnmpLP mylp)
ap
- The message to addpublic void deleteMessage(AvnmpPacket ap)
ap
- A message equal to the message to delete.AvnmpPacket.isEqual(atropos.lp.AvnmpPacket)
public AvnmpPacket getMessage(byte a, java.lang.String Src, long rt, java.lang.String Dst, long st)
a
- Anti-toggleSrc
- Source Nodert
- Receive timeDst
- Destination Nodest
- Send timepublic AvnmpPacket getGreaterRecTime(long rt)
rt
- Timepublic AvnmpPacket getGreaterOrEqualRecTime(long rt)
rt
- Timepublic AvnmpPacket getLessRecTime(long rt)
rt
- Timepublic AvnmpPacket getLessOrEqualRecTime(long rt)
rt
- Timepublic AvnmpPacket getGreaterSndTime(long st)
st
- Timepublic AvnmpPacket getGreaterOrEqualSndTime(long st)
st
- Timepublic AvnmpPacket getLessSndTime(long st)
st
- Timepublic AvnmpPacket getLessOrEqualSndTime(long st)
st
- Timepublic AvnmpPacket getVirtual()
public double numReal(long t)
pt
- Lower timet
- Upper timepublic double numVirtual(long t)
pt
- Lower timet
- Upper timepublic AvnmpPacket getReal()
public java.lang.String QtoString()
public AvnmpPacket getClosestTime(long st, AvnmpLP mylp)
st
- Timepublic AvnmpQueue append(AvnmpQueue q, AvnmpLP mylp)
q
- Queue to be appendedpublic int queueSize()
public void plotQueue(AvnmpLP mylp)
protected void cancel(AvnmpPacket cp, AvnmpLP mylp)
cp
- Message to check.mylp
- The current logical process.public int compare(java.lang.Object o1, java.lang.Object o2)
compare
in class OrderedList
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |