Rename flushAndWrite() to writeAndFlush()

- Related: #2066
This commit is contained in:
Trustin Lee 2013-12-16 14:58:14 +09:00
parent c3891a3df4
commit 82b6e75b96
2 changed files with 5 additions and 5 deletions

View File

@ -154,13 +154,13 @@ public interface ChannelGroup extends Set<Channel>, Comparable<ChannelGroup> {
/** /**
* Shortcut for calling {@link #write(Object)} and {@link #flush()}. * Shortcut for calling {@link #write(Object)} and {@link #flush()}.
*/ */
ChannelGroupFuture flushAndWrite(Object message); ChannelGroupFuture writeAndFlush(Object message);
/** /**
* Shortcut for calling {@link #write(Object)} and {@link #flush()} and only act on * Shortcut for calling {@link #write(Object)} and {@link #flush()} and only act on
* {@link Channel}s that match the {@link ChannelMatcher}. * {@link Channel}s that match the {@link ChannelMatcher}.
*/ */
ChannelGroupFuture flushAndWrite(Object message, ChannelMatcher matcher); ChannelGroupFuture writeAndFlush(Object message, ChannelMatcher matcher);
/** /**
* Disconnects all {@link Channel}s in this group from their remote peers. * Disconnects all {@link Channel}s in this group from their remote peers.

View File

@ -219,8 +219,8 @@ public class DefaultChannelGroup extends AbstractSet<Channel> implements Channel
} }
@Override @Override
public ChannelGroupFuture flushAndWrite(Object message) { public ChannelGroupFuture writeAndFlush(Object message) {
return flushAndWrite(message, ChannelMatchers.all()); return writeAndFlush(message, ChannelMatchers.all());
} }
@Override @Override
@ -303,7 +303,7 @@ public class DefaultChannelGroup extends AbstractSet<Channel> implements Channel
} }
@Override @Override
public ChannelGroupFuture flushAndWrite(Object message, ChannelMatcher matcher) { public ChannelGroupFuture writeAndFlush(Object message, ChannelMatcher matcher) {
if (message == null) { if (message == null) {
throw new NullPointerException("message"); throw new NullPointerException("message");
} }