public class DeliveryInstructions extends DataStructureImpl
| Modifier and Type | Field and Description |
|---|---|
static int | DELIVERY_MODE_DESTINATIONDELIVERY_MODE_DESTINATION. |
static int | DELIVERY_MODE_LOCALDELIVERY_MODE_LOCAL. |
static int | DELIVERY_MODE_ROUTERDELIVERY_MODE_ROUTER. |
static int | DELIVERY_MODE_TUNNELDELIVERY_MODE_TUNNEL. |
static DeliveryInstructions | LOCALImmutable local instructions, no options |
| Constructor and Description |
|---|
DeliveryInstructions()DeliveryInstructions. |
| Modifier and Type | Method and Description |
|---|---|
static DeliveryInstructions | create(byte[] data,
int offset)Returns immutable local instructions, or new |
boolean | equals(Object obj)equals. |
boolean | getDelayRequested()default false
Obsolete — delay not implemented in this release. |
long | getDelaySeconds()default 0
Obsolete — delay not implemented in this release. |
int | getDeliveryMode()default -1 |
Hash | getDestination()default null |
SessionKey | getEncryptionKey()For cloves only (not tunnels), default null
Unused — always returns null, feature not implemented. |
Hash | getRouter()default null |
int | getSize() |
TunnelId | getTunnelId()default null |
int | hashCode() |
int | readBytes(byte[] data,
int offset)readBytes. |
void | readBytes(InputStream in)Not supported, use readBytes(byte[], int) |
void | setDelayRequested(boolean req)default false
Obsolete — delay not implemented in this release. |
void | setDelaySeconds(long seconds)default 0
Obsolete — delay not implemented in this release. |
void | setDeliveryMode(int mode) |
void | setDestination(Hash dest)required for DESTINATION |
void | setRouter(Hash router)required for ROUTER or TUNNEL |
void | setTunnelId(TunnelId id)required for TUNNEL |
String | toString()toString. |
int | writeBytes(byte[] target,
int offset) |
void | writeBytes(OutputStream out)Not supported, use writeBytes(byte[], int) |
calculateHash, fromBase64, fromByteArray, read, toBase64, toByteArraypublic static final int DELIVERY_MODE_DESTINATION
public static final int DELIVERY_MODE_LOCAL
public static final int DELIVERY_MODE_ROUTER
public static final int DELIVERY_MODE_TUNNEL
public static final DeliveryInstructions LOCAL
public static DeliveryInstructions create(byte[] data, int offset)
public boolean getDelayRequested()
public long getDelaySeconds()
public int getDeliveryMode()
public Hash getDestination()
public SessionKey getEncryptionKey()
public Hash getRouter()
public int getSize()
public TunnelId getTunnelId()
public int readBytes(byte[] data,
int offset)public void readBytes(InputStream in)
in - stream to read fromUnsupportedOperationException - alwayspublic void setDelayRequested(boolean req)
public void setDelaySeconds(long seconds)
public void setDeliveryMode(int mode)
mode - 0-3public void setDestination(Hash dest)
public void setRouter(Hash router)
public void setTunnelId(TunnelId id)
public int writeBytes(byte[] target,
int offset)public void writeBytes(OutputStream out)
out - stream to write toUnsupportedOperationException - always