public class TunnelId extends Object
TunnelId provides unique identification within tunnel routing:
Constraints and Validation:
Usage in I2P:
Performance Considerations:
Security Aspects:
Implementation Notes:
Constants:
MAX_ID_VALUE - Maximum allowed tunnel ID (0xffffffff)| Modifier and Type | Field and Description |
|---|---|
static long |
MAX_ID_VALUE |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
long |
getTunnelId() |
int |
hashCode() |
void |
readBytes(InputStream in) |
void |
setTunnelId(long id)
Sets the tunnel ID for this lease.
|
String |
toString() |
void |
writeBytes(OutputStream out) |
public static final long MAX_ID_VALUE
public TunnelId()
public TunnelId(long id)
id - 1 to 0xffffffffIllegalArgumentException - if less than or equal to zero or greater than max valuepublic long getTunnelId()
public void readBytes(InputStream in) throws DataFormatException, IOException
DataFormatExceptionIOExceptionpublic void setTunnelId(long id)
id - 1 to 0xffffffffIllegalArgumentException - if less than or equal to zero or greater than max valuepublic void writeBytes(OutputStream out) throws DataFormatException, IOException
DataFormatExceptionIOException