Package net.i2p.router.message
Class PayloadGarlicConfig
java.lang.Object
net.i2p.router.message.GarlicConfig
net.i2p.router.message.PayloadGarlicConfig
Garlic config for a single clove, containing an I2NP message and no sub-cloves.
It is used for individual cloves in a Garlic Message, and as the configuration
for a single garlic-wrapped message by netdb MessageWrapper and tunnel TestJob.
-
Constructor Summary
ConstructorsConstructorDescriptionPayloadGarlicConfig(Certificate cert, long id, long expiration, DeliveryInstructions di, I2NPMessage message) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddClove(GarlicConfig config) Add a clove to the current message - if any cloves are added, an I2NP message cannot be specified via setPayload.voidgetClove(int index) intSpecify the I2NP message to be sent - if this is set, no other cloves can be included in this blockprotected StringMethods inherited from class net.i2p.router.message.GarlicConfig
getCertificate, getDeliveryInstructions, getExpiration, getId, getRecipient, getRecipientPublicKey, setRecipient, setRecipientPublicKey, toString
-
Constructor Details
-
PayloadGarlicConfig
public PayloadGarlicConfig(Certificate cert, long id, long expiration, DeliveryInstructions di, I2NPMessage message)
-
-
Method Details
-
getPayload
Specify the I2NP message to be sent - if this is set, no other cloves can be included in this block -
getSubData
- Overrides:
getSubDatain classGarlicConfig
-
addClove
Description copied from class:GarlicConfigAdd a clove to the current message - if any cloves are added, an I2NP message cannot be specified via setPayload. This means that the resulting GarlicClove represented by this GarlicConfig must be a GarlicMessage itself- Overrides:
addClovein classGarlicConfig- Throws:
UnsupportedOperationException- always- Since:
- 0.9.12
-
getCloveCount
public int getCloveCount()- Overrides:
getCloveCountin classGarlicConfig- Returns:
- zero
- Since:
- 0.9.12
-
getClove
- Overrides:
getClovein classGarlicConfig- Throws:
UnsupportedOperationException- always- Since:
- 0.9.12
-
clearCloves
public void clearCloves()- Overrides:
clearClovesin classGarlicConfig- Since:
- 0.9.12
-