Package net.i2p.i2ptunnel.udp
Class I2PSink
java.lang.Object
net.i2p.i2ptunnel.udp.I2PSink
- All Implemented Interfaces:
Sink
Producer
This sends to a fixed destination specified in the constructor
- Author:
- welterde
-
Field Summary
Modifier and TypeFieldDescriptionprotected final Destination
protected final I2PDatagramMaker
protected final boolean
protected final I2PSession
protected final int
-
Constructor Summary
ConstructorDescriptionI2PSink
(I2PSession sess, Destination dest) repliable (not raw)I2PSink
(I2PSession sess, Destination dest, boolean raw) I2PSink
(I2PSession sess, Destination dest, boolean raw, int toPort) -
Method Summary
Modifier and TypeMethodDescriptionvoid
send
(Destination src, int fromPort, int ign_toPort, byte[] data)
-
Field Details
-
raw
protected final boolean raw -
sess
-
dest
-
maker
-
toPort
protected final int toPort- Since:
- 0.9.53
-
-
Constructor Details
-
I2PSink
repliable (not raw) -
I2PSink
- Parameters:
raw
- false for repliable
-
I2PSink
- Parameters:
raw
- false for repliabletoPort
- I2CP destination port, 0-65535- Since:
- 0.9.53
-
-
Method Details
-
send
- Specified by:
send
in interfaceSink
- Parameters:
src
- ignoredfromPort
- I2CP portign_toPort
- ignored- Throws:
RuntimeException
- if session is closed- Since:
- 0.9.53 added fromPort and toPort parameters, breaking change, sorry
-