All Packages This Package Class Hierarchy Class Search Index
java.lang.Object | +----edu.utah.janos.antsr.core.Capsule | +----edu.utah.janos.antsr.core.DLRequestCapsule
Summary |
final class DLRequestCapsule extends edu.utah.janos.antsr.core.Capsule { // Fields 5 static final byte[] MID; private static final byte[] PID; public static final String VERSION; int wantedChunkMask; private TypeID wantedID; // Constructors 2 DLRequestCapsule(); DLRequestCapsule(int, TypeID); // Methods 7 public Xdr decode(); public Xdr encode(); public boolean evaluate(Node); public int length(); protected byte[] mid(); protected byte[] pid(); public String toString(); }
Demand Load Request capsule.
DLRequestCapsules are created in only one place:
ProtocolBooster.startNewMid()
. See ProtocolBooster
for an explaination of why it will create DLRequestCapsules.
The DLRequestCapsule adds two fields to the base Capsule:
See Also: CodeGroup, DLProtocol, DLResponseCapsule, ProtocolBooster
Fields |
· VERSION | Summary | Top |
public static final String VERSION
· MID | Summary | Top |
static final byte[] MID
· PID | Summary | Top |
private static final byte[] PID
· wantedID | Summary | Top |
private TypeID wantedID
The TypeID of the CapsuleClass this Capsule is intended to load. This is set only by the constructor (for outgoing DLRequestCapsules) or by the decode() function (for incoming DLRequestCapsules).
· wantedChunkMask | Summary | Top |
int wantedChunkMask
The mask of chunks the requesting node needs to finish the appropriate CodeGroup.
Constructors |
· DLRequestCapsule | Summary | Top |
DLRequestCapsule()
Create a blank DLRequestCapsule.
This constructor should only be invoked when a DLRequestCapsule is being received and decoded.
· DLRequestCapsule | Summary | Top |
DLRequestCapsule(int dst, TypeID mid)
Create a DLRequestCapsule for a specific MID.
All chunks of the relevant CodeGroup will be requested.
Only invoked by ProtocolBooster.startNewMid()
See Also: startNewMid
Methods |
· mid | Summary | Top |
protected byte[] mid()
- Overrides:
- mid in class Capsule
· pid | Summary | Top |
protected byte[] pid()
- Overrides:
- pid in class Capsule
· length | Summary | Top |
public int length()
- Overrides:
- length in class Capsule
· encode | Summary | Top |
public Xdr encode()
- Overrides:
- encode in class Capsule
· decode | Summary | Top |
public Xdr decode()
- Overrides:
- decode in class Capsule
· evaluate | Summary | Top |
public boolean evaluate(Node node)
Evaluate a DLRequestCapsule. Based on the wantedID stored in this capsule, lookup the CapsuleClass on the local node. If the CapsuleClass is not available drop the request on the floor. Otherwise, send DLResponseCapsules for each and every chunk the requestor doesn't have the in appropriate
CodeGroup .Note that CapsuleClasses for the builtin CodeGroups are not transferrable.
- Overrides:
- evaluate in class Capsule
See Also: CodeGroup
· toString | Summary | Top |
public String toString()
- Overrides:
- toString in class Capsule
All Packages This Package Class Hierarchy Class Search IndexFreshly brewed Java API Documentation automatically generated with polardoc Version 1.0.7