Update Javadoc of ByteBufProcessor and MessageListProcessor

- in response to @shacharo's suggestion
This commit is contained in:
Trustin Lee 2013-06-27 19:01:01 +09:00
parent ac39cad5ff
commit 52691488ee
2 changed files with 6 additions and 2 deletions

View File

@ -165,7 +165,9 @@ public interface ByteBufProcessor {
/** /**
* @return the number of elements processed. {@link ByteBuf#forEachByte(ByteBufProcessor)} will determine * @return the number of elements processed. {@link ByteBuf#forEachByte(ByteBufProcessor)} will determine
* the index of the next byte to be processed based on this value. Usually, an implementation will * the index of the next byte to be processed based on this value. Usually, an implementation will
* return {@code 1} to advance the index by {@code 1}. * return {@code 1} to advance the index by {@code 1}. Note that returning a non-positive value is
* allowed where a negative value advances the index in the opposite direction and zero leaves the index
* as-is.
*/ */
int process(ByteBuf buf, int index, byte value) throws Exception; int process(ByteBuf buf, int index, byte value) throws Exception;
} }

View File

@ -25,7 +25,9 @@ public interface MessageListProcessor<T> {
/** /**
* @return the number of elements processed. {@link MessageList#forEach(MessageListProcessor)} will determine * @return the number of elements processed. {@link MessageList#forEach(MessageListProcessor)} will determine
* the index of the next element to be processed based on this value. Usually, an implementation will * the index of the next element to be processed based on this value. Usually, an implementation will
* return {@code 1} to advance the index by {@code 1}. * return {@code 1} to advance the index by {@code 1}. Note that returning a non-positive value is
* allowed where a negative value advances the index in the opposite direction and zero leaves the index
* as-is.
*/ */
int process(MessageList<T> messages, int index, T value) throws Exception; int process(MessageList<T> messages, int index, T value) throws Exception;
} }