javadoc fixes part 9 (ticket #1894)

This commit is contained in:
zzz
2017-01-27 01:41:06 +00:00
parent 5db89d8743
commit fb74f41692
19 changed files with 40 additions and 40 deletions

View File

@@ -26,7 +26,7 @@ public class I2PSocketAddress extends SocketAddress {
* Does a naming service lookup to resolve the dest.
* May take several seconds for b32.
* @param host hostname or b64 dest or b32, may have :port appended
* @throws IllegalArgumentException for port < 0 or port > 65535 or invalid port
* @throws IllegalArgumentException for port &lt; 0 or port &gt; 65535 or invalid port
* @since 0.9.9
*/
public I2PSocketAddress(String host) {
@@ -51,7 +51,7 @@ public class I2PSocketAddress extends SocketAddress {
/**
* Does not do a reverse lookup. Host will be null.
* @throws IllegalArgumentException for port < 0 or port > 65535
* @throws IllegalArgumentException for port &lt; 0 or port &gt; 65535
*/
public I2PSocketAddress(Destination dest, int port) {
if (dest == null)
@@ -66,7 +66,7 @@ public class I2PSocketAddress extends SocketAddress {
/**
* Does a naming service lookup to resolve the dest.
* May take several seconds for b32.
* @throws IllegalArgumentException for port < 0 or port > 65535
* @throws IllegalArgumentException for port &lt; 0 or port &gt; 65535
*/
public I2PSocketAddress(String host, int port) {
if (port < 0 || port > 65535)
@@ -77,7 +77,7 @@ public class I2PSocketAddress extends SocketAddress {
}
/**
* @throws IllegalArgumentException for port < 0 or port > 65535
* @throws IllegalArgumentException for port &lt; 0 or port &gt; 65535
*/
public static I2PSocketAddress createUnresolved(String host, int port) {
return new I2PSocketAddress(port, host);

View File

@@ -32,7 +32,7 @@ public class I2PSocketException extends SocketException {
* Standard codes from client-side I2CP are 256-511, defined in SendMessageStatusListener.
* Standard codes from streaming are 512-767, defined here.
*
* @param status >= 0 from MessageStatusMessage or SendMessageStatusListener
* @param status &gt;= 0 from MessageStatusMessage or SendMessageStatusListener
*/
public I2PSocketException(int status) {
super();

View File

@@ -240,7 +240,7 @@ public interface I2PSocketManager {
/**
* Like connect() but returns a real Socket, and throws only IOE,
* for easier porting of apps.
* @param timeout ms if > 0, forces blocking (disables connectDelay)
* @param timeout ms if &gt; 0, forces blocking (disables connectDelay)
* @since 0.8.4
*/
public Socket connectToSocket(Destination peer, int timeout) throws IOException;

View File

@@ -80,7 +80,7 @@ public class I2PSocketManagerFactory {
* The nonblocking createDisconnectedManager() is preferred.
*
* @param host I2CP host null to use default, ignored if in router context
* @param port I2CP port <= 0 to use default, ignored if in router context
* @param port I2CP port &lt;= 0 to use default, ignored if in router context
* @return the newly created socket manager, or null if there were errors
*/
public static I2PSocketManager createManager(String host, int port) {
@@ -95,7 +95,7 @@ public class I2PSocketManagerFactory {
* The nonblocking createDisconnectedManager() is preferred.
*
* @param i2cpHost I2CP host null to use default, ignored if in router context
* @param i2cpPort I2CP port <= 0 to use default, ignored if in router context
* @param i2cpPort I2CP port &lt;= 0 to use default, ignored if in router context
* @param opts Streaming and I2CP options, may be null
* @return the newly created socket manager, or null if there were errors
*/
@@ -157,7 +157,7 @@ public class I2PSocketManagerFactory {
* @param myPrivateKeyStream private key stream, format is specified in {@link net.i2p.data.PrivateKeyFile PrivateKeyFile}
* or null for a transient destination. Caller must close.
* @param i2cpHost I2CP host null to use default, ignored if in router context
* @param i2cpPort I2CP port <= 0 to use default, ignored if in router context
* @param i2cpPort I2CP port &lt;= 0 to use default, ignored if in router context
* @param opts Streaming and I2CP options, may be null
* @return the newly created socket manager, or null if there were errors
*/
@@ -184,7 +184,7 @@ public class I2PSocketManagerFactory {
* @param myPrivateKeyStream private key stream, format is specified in {@link net.i2p.data.PrivateKeyFile PrivateKeyFile}
* or null for a transient destination. Caller must close.
* @param i2cpHost I2CP host null to use default, ignored if in router context
* @param i2cpPort I2CP port <= 0 to use default, ignored if in router context
* @param i2cpPort I2CP port &lt;= 0 to use default, ignored if in router context
* @param opts Streaming and I2CP options, may be null
* @return the newly created socket manager, non-null (throws on error)
* @since 0.9.8
@@ -216,7 +216,7 @@ public class I2PSocketManagerFactory {
* @param myPrivateKeyStream private key stream, format is specified in {@link net.i2p.data.PrivateKeyFile PrivateKeyFile}
* non-null. Caller must close.
* @param i2cpHost I2CP host null to use default, ignored if in router context
* @param i2cpPort I2CP port <= 0 to use default, ignored if in router context
* @param i2cpPort I2CP port &lt;= 0 to use default, ignored if in router context
* @param opts Streaming and I2CP options, may be null
* @param connect true to connect (blocking)
* @return the newly created socket manager, non-null (throws on error)

View File

@@ -18,7 +18,7 @@ public interface I2PSocketOptions {
* How long we will wait for the ACK from a SYN, in milliseconds.
*
* Default 60 seconds. Max of 2 minutes enforced in Connection.java,
* and it also interprets <= 0 as default.
* and it also interprets &lt;= 0 as default.
*
* @return milliseconds to wait, or -1 if we will wait indefinitely
*/
@@ -28,7 +28,7 @@ public interface I2PSocketOptions {
* Define how long we will wait for the ACK from a SYN, in milliseconds.
*
* Default 60 seconds. Max of 2 minutes enforced in Connection.java,
* and it also interprets <= 0 as default.
* and it also interprets &lt;= 0 as default.
*
* @param ms timeout in ms
*/

View File

@@ -177,7 +177,7 @@ class Connection {
*
* @param timeoutMs 0 or negative means wait forever, 5 minutes max
* @return true if the packet should be sent, false for a fatal error
* will return false after 5 minutes even if timeoutMs is <= 0.
* will return false after 5 minutes even if timeoutMs is &lt;= 0.
*/
public boolean packetSendChoke(long timeoutMs) throws IOException, InterruptedException {
long start = _context.clock().now();
@@ -635,7 +635,7 @@ class Connection {
/**
* Always true at the start, even if we haven't gotten a reply on an
* outbound connection. Only set to false on disconnect.
* For outbound, use getHighestAckedThrough() >= 0 also,
* For outbound, use getHighestAckedThrough() &gt;= 0 also,
* to determine if the connection is up.
*
* In general, this is true until either:
@@ -961,9 +961,9 @@ class Connection {
}
/**
* If the next send time is currently >= 0 (i.e. not "never"),
* If the next send time is currently &gt;= 0 (i.e. not "never"),
* this may make the next time sooner but will not make it later.
* If the next send time is currently < 0 (i.e. "never"),
* If the next send time is currently &lt; 0 (i.e. "never"),
* this will set it to the time specified, but not later than
* options.getSendAckDelay() from now (1000 ms)
*/
@@ -1328,7 +1328,7 @@ class Connection {
* we have to use forceReschedule() instead of schedule() below,
* to prevent duplicates in the timer queue.
*
* don't synchronize this, deadlock with ackPackets->ackReceived->SimpleTimer2.cancel
* don't synchronize this, deadlock with ackPackets-&gt;ackReceived-&gt;SimpleTimer2.cancel
*
* @return true if the packet was sent, false if it was not
*/

View File

@@ -11,7 +11,7 @@ import net.i2p.util.Log;
* delivery, or even the generation of a new packet. This class
* is the only one that builds useful outbound Packet objects.
*<p>
* MessageOutputStream -> ConnectionDataReceiver -> Connection -> PacketQueue -> I2PSession
* MessageOutputStream -&gt; ConnectionDataReceiver -&gt; Connection -&gt; PacketQueue -&gt; I2PSession
*<p>
* There's one of these per MessageOutputStream.
* It stores no state. It sends everything to the Connection unless
@@ -36,7 +36,7 @@ class ConnectionDataReceiver implements MessageOutputStream.DataReceiver {
* This tells the flusher in MessageOutputStream whether to flush.
* It won't flush if this returns true.
*
* It was: return con.getUnackedPacketsSent() > 0 (i.e. Nagle)
* It was: return con.getUnackedPacketsSent() &gt; 0 (i.e. Nagle)
* But then, for data that fills more than one packet, the last part of
* the data isn't sent until all the previous packets are acked. Which is very slow.
* The poor interaction of Nagle and Delayed Acknowledgements is well-documented.

View File

@@ -13,7 +13,7 @@ import net.i2p.util.SimpleTimer;
* Receive a packet for a particular connection - placing the data onto the
* queue, marking packets as acked, updating various fields, etc.
*<p>
* I2PSession -> MessageHandler -> PacketHandler -> ConnectionPacketHandler -> MessageInputStream
* I2PSession -&gt; MessageHandler -&gt; PacketHandler -&gt; ConnectionPacketHandler -&gt; MessageInputStream
*<p>
* One of these is instantiated per-Destination
* (i.e. per-ConnectionManager, not per-Connection).

View File

@@ -632,7 +632,7 @@ public class I2PSocketManagerFull implements I2PSocketManager {
/**
* Like connect() but returns a real Socket, and throws only IOE,
* for easier porting of apps.
* @param timeout ms if > 0, forces blocking (disables connectDelay)
* @param timeout ms if &gt; 0, forces blocking (disables connectDelay)
* @since 0.8.4
*/
public Socket connectToSocket(Destination peer, int timeout) throws IOException {

View File

@@ -122,7 +122,7 @@ class I2PSocketOptionsImpl implements I2PSocketOptions {
* How long we will wait for the ACK from a SYN, in milliseconds.
*
* Default 60 seconds. Max of 2 minutes enforced in Connection.java,
* and it also interprets <= 0 as default.
* and it also interprets &lt;= 0 as default.
*
* @return milliseconds to wait, or -1 if we will wait indefinitely
*/
@@ -134,7 +134,7 @@ class I2PSocketOptionsImpl implements I2PSocketOptions {
* Define how long we will wait for the ACK from a SYN, in milliseconds.
*
* Default 60 seconds. Max of 2 minutes enforced in Connection.java,
* and it also interprets <= 0 as default.
* and it also interprets &lt;= 0 as default.
*
*/
public void setConnectTimeout(long ms) {

View File

@@ -14,8 +14,8 @@ import net.i2p.util.Log;
/**
* Receive raw information from the I2PSession and turn it into
* Packets, if we can.
*<p>
* I2PSession -> MessageHandler -> PacketHandler -> ConnectionPacketHandler -> MessageInputStream
*&lt;p&gt;
* I2PSession -&gt; MessageHandler -&gt; PacketHandler -&gt; ConnectionPacketHandler -&gt; MessageInputStream
*/
class MessageHandler implements I2PSessionMuxedListener {
private final ConnectionManager _manager;

View File

@@ -16,9 +16,9 @@ import net.i2p.util.Log;
/**
* Stream that can be given messages out of order
* yet present them in order.
*<p>
* I2PSession -> MessageHandler -> PacketHandler -> ConnectionPacketHandler -> MessageInputStream
*<p>
*&lt;p&gt;
* I2PSession -&gt; MessageHandler -&gt; PacketHandler -&gt; ConnectionPacketHandler -&gt; MessageInputStream
*&lt;p&gt;
* This buffers unlimited data via messageReceived() -
* limiting / blocking is done in ConnectionPacketHandler.receivePacket().
*

View File

@@ -16,8 +16,8 @@ import net.i2p.util.SimpleTimer2;
* A stream that we can shove data into that fires off those bytes
* on flush or when the buffer is full. It also blocks according
* to the data receiver's needs.
*<p>
* MessageOutputStream -> ConnectionDataReceiver -> Connection -> PacketQueue -> I2PSession
*&lt;p&gt;
* MessageOutputStream -&gt; ConnectionDataReceiver -&gt; Connection -&gt; PacketQueue -&gt; I2PSession
*/
class MessageOutputStream extends OutputStream {
private final I2PAppContext _context;

View File

@@ -232,7 +232,7 @@ class Packet {
}
/**
* @param id if < 0, sets FLAG_NO_ACK
* @param id if &lt; 0, sets FLAG_NO_ACK
*/
public void setAckThrough(long id) {
if (id < 0)

View File

@@ -11,8 +11,8 @@ import net.i2p.util.Log;
/**
* receive a packet and dispatch it correctly to the connection specified,
* the server socket, or queue a reply RST packet.
*<p>
* I2PSession -> MessageHandler -> PacketHandler -> ConnectionPacketHandler -> MessageInputStream
*&lt;p&gt;
* I2PSession -&gt; MessageHandler -&gt; PacketHandler -&gt; ConnectionPacketHandler -&gt; MessageInputStream
*/
class PacketHandler {
private final ConnectionManager _manager;

View File

@@ -23,8 +23,8 @@ import net.i2p.util.SimpleTimer2;
* Well, thats the theory at least... in practice we just
* send them immediately with no blocking, since the
* mode=bestEffort doesnt block in the SDK.
*<p>
* MessageOutputStream -> ConnectionDataReceiver -> Connection -> PacketQueue -> I2PSession
*&lt;p&gt;
* MessageOutputStream -&gt; ConnectionDataReceiver -&gt; Connection -&gt; PacketQueue -&gt; I2PSession
*/
class PacketQueue implements SendMessageStatusListener, Closeable {
private final I2PAppContext _context;

View File

@@ -21,7 +21,7 @@ import net.i2p.client.streaming.I2PSocketOptions;
* null for some methods.
*
* StandardSockets are always bound, and always start out connected
* (unless connectDelay is > 0).
* (unless connectDelay is &gt; 0).
* You may not create an unbound StandardSocket.
* Create this through the SocketManager.
*

View File

@@ -43,7 +43,7 @@ import net.i2p.util.Log;
* to implement something with a zero false positive rate, and uses less memory
* for almost all bandwidth classes.
*
* This has a strictly zero false positive rate for <= 8 byte keys.
* This has a strictly zero false positive rate for &lt;= 8 byte keys.
* For larger keys, it is 1 / (2**64) ~= 5E-20, which is better than
* DBF for any entry count greater than about 14K.
*
@@ -208,7 +208,7 @@ public class DecayingHashSet extends DecayingBloomFilter {
}
/**
* This saves the data as-is if the length is <= 8 bytes,
* This saves the data as-is if the length is &lt;= 8 bytes,
* otherwise it stores an 8-byte hash.
* Hash function is from DataHelper, modded to get
* the maximum entropy given the length of the data.

View File

@@ -61,7 +61,7 @@ public class KeySelector {
* Note that if k and m are too big, the GenericWordSelector blows up -
* The max for 32-byte keys is m=23 and k=11.
* The precise restriction appears to be:
* ((5k + (k-1)(m-5)) / 8) + 2 < keySizeInBytes
* ((5k + (k-1)(m-5)) / 8) + 2 &lt; keySizeInBytes
*
* It isn't clear how to fix this.
*/