Fix errors reported by javadoc

Motivation:

Javadoc reports errors about invalid docs.

Modifications:

Fix some errors reported by javadoc.

Result:

A lot of javadoc errors are fixed by this patch.
This commit is contained in:
Xiaoyan Lin 2015-12-26 22:19:11 -08:00 committed by Norman Maurer
parent a96d52fe66
commit 475d901131
20 changed files with 32 additions and 39 deletions

View File

@ -494,7 +494,7 @@ public abstract class ByteBuf implements ReferenceCounted, Comparable<ByteBuf> {
* @param minWritableBytes
* the expected minimum number of writable bytes
* @throws IndexOutOfBoundsException
* if {@link #writerIndex()} + {@code minWritableBytes} > {@link #maxCapacity()}
* if {@link #writerIndex()} + {@code minWritableBytes} &gt; {@link #maxCapacity()}
*/
public abstract ByteBuf ensureWritable(int minWritableBytes);
@ -506,7 +506,7 @@ public abstract class ByteBuf implements ReferenceCounted, Comparable<ByteBuf> {
* @param minWritableBytes
* the expected minimum number of writable bytes
* @param force
* When {@link #writerIndex()} + {@code minWritableBytes} > {@link #maxCapacity()}:
* When {@link #writerIndex()} + {@code minWritableBytes} &gt; {@link #maxCapacity()}:
* <ul>
* <li>{@code true} - the capacity of the buffer is expanded to {@link #maxCapacity()}</li>
* <li>{@code false} - the capacity of the buffer is unchanged</li>

View File

@ -27,7 +27,7 @@ package io.netty.handler.codec.http;
* separately via {@link io.netty.handler.codec.http.cookie.ServerCookieDecoder},
* {@link io.netty.handler.codec.http.cookie.ClientCookieDecoder},
* {@link io.netty.handler.codec.http.cookie.ServerCookieEncoder},
* and {@link @io.netty.handler.codec.http.cookie.ClientCookieEncoder}.
* and {@link io.netty.handler.codec.http.cookie.ClientCookieEncoder}.
*
* @see HttpResponse
* @see io.netty.handler.codec.http.cookie.ServerCookieDecoder

View File

@ -24,7 +24,7 @@ package io.netty.handler.codec.http;
* separately via {@link io.netty.handler.codec.http.cookie.ServerCookieDecoder},
* {@link io.netty.handler.codec.http.cookie.ClientCookieDecoder},
* {@link io.netty.handler.codec.http.cookie.ServerCookieEncoder},
* and {@link @io.netty.handler.codec.http.cookie.ClientCookieEncoder}.
* and {@link io.netty.handler.codec.http.cookie.ClientCookieEncoder}.
*
* @see HttpRequest
* @see io.netty.handler.codec.http.cookie.ServerCookieDecoder

View File

@ -26,7 +26,7 @@ import io.netty.handler.codec.http.HttpObjectDecoder;
import io.netty.handler.codec.http.HttpResponseStatus;
/**
* Decodes {@link ByteBuf}s into RTSP messages represented in
* Decodes {@link io.netty.buffer.ByteBuf}s into RTSP messages represented in
* {@link HttpMessage}s.
* <p>
* <h3>Parameters that prevents excessive memory consumption</h3>
@ -39,18 +39,18 @@ import io.netty.handler.codec.http.HttpResponseStatus;
* <td>The maximum length of the initial line
* (e.g. {@code "SETUP / RTSP/1.0"} or {@code "RTSP/1.0 200 OK"})
* If the length of the initial line exceeds this value, a
* {@link TooLongFrameException} will be raised.</td>
* {@link io.netty.handler.codec.TooLongFrameException} will be raised.</td>
* </tr>
* <tr>
* <td>{@code maxHeaderSize}</td>
* <td>The maximum length of all headers. If the sum of the length of each
* header exceeds this value, a {@link TooLongFrameException} will be
* header exceeds this value, a {@link io.netty.handler.codec.TooLongFrameException} will be
* raised.</td>
* </tr>
* <tr>
* <td>{@code maxContentLength}</td>
* <td>The maximum length of the content. If the content length exceeds this
* value, a {@link TooLongFrameException} will be raised.</td>
* value, a {@link io.netty.handler.codec.TooLongFrameException} will be raised.</td>
* </tr>
* </table>
*/

View File

@ -35,7 +35,7 @@ public interface Http2FrameListener {
* {@code WINDOW_UPDATE}). Returning a value equal to the length of {@code data} + {@code padding} will effectively
* opt-out of application-level flow control for this frame. Returning a value less than the length of {@code data}
* + {@code padding} will defer the returning of the processed bytes, which the application must later return via
* {@link Http2LocalFlowController#consumeBytes(ChannelHandlerContext, Http2Stream, int)}. The returned value must
* {@link Http2LocalFlowController#consumeBytes(Http2Stream, int)}. The returned value must
* be >= {@code 0} and <= {@code data.readableBytes()} + {@code padding}.
*/
int onDataRead(ChannelHandlerContext ctx, int streamId, ByteBuf data, int padding,

View File

@ -134,7 +134,7 @@ public final class WeightedFairQueueByteDistributor implements StreamByteDistrib
/**
* Sets the amount of bytes that will be allocated to each stream. Defaults to 1KiB.
* @param allocationQuantum the amount of bytes that will be allocated to each stream. Must be > 0.
* @param allocationQuantum the amount of bytes that will be allocated to each stream. Must be &gt; 0.
*/
public void allocationQuantum(int allocationQuantum) {
if (allocationQuantum <= 0) {

View File

@ -47,8 +47,8 @@ public final class AttributeKey<T> extends AbstractConstant<AttributeKey<T>> {
}
/**
* Creates a new {@link AttributeKey} for the given {@param name} or fail with an
* {@link IllegalArgumentException} if a {@link AttributeKey} for the given {@param name} exists.
* Creates a new {@link AttributeKey} for the given {@code name} or fail with an
* {@link IllegalArgumentException} if a {@link AttributeKey} for the given {@code name} exists.
*/
@SuppressWarnings("unchecked")
public static <T> AttributeKey<T> newInstance(String name) {

View File

@ -79,8 +79,8 @@ public abstract class ConstantPool<T extends Constant<T>> {
}
/**
* Creates a new {@link Constant} for the given {@param name} or fail with an
* {@link IllegalArgumentException} if a {@link Constant} for the given {@param name} exists.
* Creates a new {@link Constant} for the given {@code name} or fail with an
* {@link IllegalArgumentException} if a {@link Constant} for the given {@code name} exists.
*/
@SuppressWarnings("unchecked")
public T newInstance(String name) {

View File

@ -127,7 +127,7 @@ public class HashedWheelTimer implements Timer {
* @param tickDuration the duration between tick
* @param unit the time unit of the {@code tickDuration}
* @throws NullPointerException if {@code unit} is {@code null}
* @throws IllegalArgumentException if {@code tickDuration} is <= 0
* @throws IllegalArgumentException if {@code tickDuration} is &lt;= 0
*/
public HashedWheelTimer(long tickDuration, TimeUnit unit) {
this(Executors.defaultThreadFactory(), tickDuration, unit);
@ -141,7 +141,7 @@ public class HashedWheelTimer implements Timer {
* @param unit the time unit of the {@code tickDuration}
* @param ticksPerWheel the size of the wheel
* @throws NullPointerException if {@code unit} is {@code null}
* @throws IllegalArgumentException if either of {@code tickDuration} and {@code ticksPerWheel} is <= 0
* @throws IllegalArgumentException if either of {@code tickDuration} and {@code ticksPerWheel} is &lt;= 0
*/
public HashedWheelTimer(long tickDuration, TimeUnit unit, int ticksPerWheel) {
this(Executors.defaultThreadFactory(), tickDuration, unit, ticksPerWheel);
@ -169,7 +169,7 @@ public class HashedWheelTimer implements Timer {
* @param tickDuration the duration between tick
* @param unit the time unit of the {@code tickDuration}
* @throws NullPointerException if either of {@code threadFactory} and {@code unit} is {@code null}
* @throws IllegalArgumentException if {@code tickDuration} is <= 0
* @throws IllegalArgumentException if {@code tickDuration} is &lt;= 0
*/
public HashedWheelTimer(
ThreadFactory threadFactory, long tickDuration, TimeUnit unit) {
@ -186,7 +186,7 @@ public class HashedWheelTimer implements Timer {
* @param unit the time unit of the {@code tickDuration}
* @param ticksPerWheel the size of the wheel
* @throws NullPointerException if either of {@code threadFactory} and {@code unit} is {@code null}
* @throws IllegalArgumentException if either of {@code tickDuration} and {@code ticksPerWheel} is <= 0
* @throws IllegalArgumentException if either of {@code tickDuration} and {@code ticksPerWheel} is &lt;= 0
*/
public HashedWheelTimer(
ThreadFactory threadFactory,

View File

@ -24,8 +24,8 @@ import java.util.Set;
* into one, by listening to individual {@link Future}s and producing an aggregated result
* (success/failure) when all {@link Future}s have completed.
*
* @tparam V the type of value returned by the {@link Future}
* @tparam F the type of {@link Future}
* @param <V> the type of value returned by the {@link Future}
* @param <F> the type of {@link Future}
*/
public class PromiseAggregator<V, F extends Future<V>> implements GenericFutureListener<F> {

View File

@ -40,7 +40,7 @@ import java.util.Queue;
* <li>{@link #poll()} and {@link #remove()}</li>
* <li>{@link #element()}, {@link #peek()}</li>
* <li>{@link #remove(Object)}, {@link #removeAll(Collection)}, and {@link #retainAll(Collection)}</li>
* <li>{@link #clear()}</li> {@link #}
* <li>{@link #clear()}</li>
* <li>{@link #iterator()}</li>
* <li>{@link #toArray()} and {@link #toArray(Object[])}</li>
* <li>{@link #contains(Object)} and {@link #containsAll(Collection)}</li>

View File

@ -29,7 +29,7 @@ import java.util.List;
public final class Http2ExampleUtil {
/**
* Response header sent in response to the http->http2 cleartext upgrade request.
* Response header sent in response to the http-&gt;http2 cleartext upgrade request.
*/
public static final String UPGRADE_RESPONSE_HEADER = "http-to-http2-upgrade";

View File

@ -59,7 +59,7 @@ public class HttpResponseHandler extends SimpleChannelInboundHandler<FullHttpRes
*
* @param timeout Value of time to wait for each response
* @param unit Units associated with {@code timeout}
* @see HttpResponseHandler#put(int, io.netty.channel.ChannelPromise)
* @see HttpResponseHandler#put(int, io.netty.channel.ChannelFuture, io.netty.channel.ChannelPromise)
*/
public void awaitResponses(long timeout, TimeUnit unit) {
Iterator<Entry<Integer, Entry<ChannelFuture, ChannelPromise>>> itr = streamidPromiseMap.entrySet().iterator();

View File

@ -633,15 +633,8 @@ public abstract class AbstractTrafficShapingHandler extends ChannelDuplexHandler
* Calculate the size of the given {@link Object}.
*
* This implementation supports {@link ByteBuf} and {@link ByteBufHolder}. Sub-classes may override this.
<<<<<<< HEAD
* @param msg the msg for which the size should be calculated
* @return size the size of the msg or {@code -1} if unknown.
=======
*
* @param msg
* the msg for which the size should be calculated.
* @param msg the msg for which the size should be calculated.
* @return size the size of the msg or {@code -1} if unknown.
>>>>>>> b886c05... Fix big transfer and Write traffic shaping issues
*/
protected long calculateSize(Object msg) {
if (msg instanceof ByteBuf) {

View File

@ -71,7 +71,7 @@ public class AbstractSharedExecutorMicrobenchmark extends AbstractMicrobenchmark
* Set the executor (in the form of an {@link EventLoop}) which JMH will use.
* <p>
* This must be called before JMH requires an executor to execute objects.
* @param eventLoop Used as an executor by JMH to run benchmarks.
* @param service Used as an executor by JMH to run benchmarks.
*/
public static void executor(EventLoop service) {
executor = service;

View File

@ -24,7 +24,7 @@ import java.nio.channels.UnsupportedAddressTypeException;
import java.util.List;
/**
* Resolves a possibility unresolved {@link {@link SocketAddress}}.
* Resolves a possibility unresolved {@link SocketAddress}.
*/
public interface AddressResolver<T extends SocketAddress> extends Closeable {

View File

@ -54,7 +54,7 @@
* }
*
* <p>08. Run the <tt>AutobahnServer</tt> located in this package. If you are in Eclipse IDE, right click on
* <tt>AutobahnServer.java</tt> and select Run As > Java Application.
* <tt>AutobahnServer.java</tt> and select Run As &gt; Java Application.
*
* <p>09. Run the Autobahn test <tt>wstest -m fuzzingclient -s fuzzingclient.json</tt>.
*

View File

@ -256,7 +256,7 @@ public interface RxtxChannelConfig extends ChannelConfig {
*
* @param waitTimeMillis The number of milliseconds to wait, defaulting to 0 (no
* wait) if unset
* @throws IllegalArgumentException if the supplied value is < 0
* @throws IllegalArgumentException if the supplied value is &lt; 0
*/
RxtxChannelConfig setWaitTimeMillis(int waitTimeMillis);

View File

@ -63,8 +63,8 @@ public class ChannelOption<T> extends AbstractConstant<ChannelOption<T>> {
}
/**
* Creates a new {@link ChannelOption} for the given {@param name} or fail with an
* {@link IllegalArgumentException} if a {@link ChannelOption} for the given {@param name} exists.
* Creates a new {@link ChannelOption} for the given {@code name} or fail with an
* {@link IllegalArgumentException} if a {@link ChannelOption} for the given {@code name} exists.
*/
@SuppressWarnings("unchecked")
public static <T> ChannelOption<T> newInstance(String name) {

View File

@ -58,8 +58,8 @@ public interface MaxBytesRecvByteBufAllocator extends RecvByteBufAllocator {
/**
* Sets the maximum number of bytes to read for a read loop and per individual read operation.
* If this value is greater than 1, an event loop might attempt to read multiple times to procure bytes.
* @param maxBytesPerRead {@see #setMaxBytesPerRead(int)}
* @param maxBytesPerIndividualRead {@see #setMaxBytesPerIndividualRead(int)}
* @param maxBytesPerRead see {@link #maxBytesPerRead(int)}
* @param maxBytesPerIndividualRead see {@link #maxBytesPerIndividualRead(int)}
*/
MaxBytesRecvByteBufAllocator maxBytesPerReadPair(int maxBytesPerRead, int maxBytesPerIndividualRead);
}