| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectrescuecore.LongUDPFragment
This is a piece of a LongUDPMessage
| Constructor Summary | |
| LongUDPFragment(byte[] input)Generate a new LongUDPFragment from some data sent by the kernal | |
| LongUDPFragment(int id,
                int number,
                int total,
                byte[] data)Generate a new LongUDPFragment ready for sending | |
| Method Summary | |
|  int | compareTo(java.lang.Object o) | 
|  byte[] | getData()Get the body of this fragment | 
|  int | getID()Get the message id of this fragment | 
|  int | getNumber()Get the sequence number of this fragment | 
|  int | getTotal()Get the total number of fragments in this fragment's message | 
|  byte[] | toByteArray()Turn this fragment into a byte array suitable for transmission to the kernal | 
|  java.lang.String | toString() | 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait | 
| Constructor Detail | 
public LongUDPFragment(int id,
                       int number,
                       int total,
                       byte[] data)
id - The id of the LongUDPMessage we are sendingnumber - The number of this fragmenttotal - The total number of fragments we are sendingdata - The body of this fragmentpublic LongUDPFragment(byte[] input)
input - The raw data from the kernal. It should consist of four 16-bit numbers (magic number, id, fragment number, total number of fragments) followed by some data.| Method Detail | 
public java.lang.String toString()
public int compareTo(java.lang.Object o)
compareTo in interface java.lang.Comparablepublic byte[] toByteArray()
public byte[] getData()
public int getID()
public int getNumber()
public int getTotal()
| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||