private class AbstractLookupDiscovery.DecodeAnnouncementTask extends Object implements Runnable
Modifier and Type | Field and Description |
---|---|
private DatagramPacket |
datagram |
Constructor and Description |
---|
DecodeAnnouncementTask(DatagramPacket datagram)
Creates a task for decoding the given multicast announcement packet.
|
Modifier and Type | Method and Description |
---|---|
private void |
doRun()
Decodes this task's multicast announcement packet.
|
private boolean |
newSeqNum(long currentNum,
long oldNum)
Returns
true if currentNum is a new sequence number
that needs to be inspected. |
void |
run()
Restore the privileged context and run
|
private final DatagramPacket datagram
public DecodeAnnouncementTask(DatagramPacket datagram)
public void run()
private void doRun()
private boolean newSeqNum(long currentNum, long oldNum)
true
if currentNum is a new sequence number
that needs to be inspected. A -1 occurs if the announcement had no
sequence number (for e.g. DiscoveryV1) or the service had been
discovered through unicast discovery. REMIND: Ideally the
message should have a flag which indicates no sequence number instead
of overloading the -1 valueCopyright 2007-2013, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.