From 1695e32b0fdbd8eafc42b0a1199e832daea84200 Mon Sep 17 00:00:00 2001 From: Trustin Lee Date: Wed, 3 Mar 2010 23:11:39 +0000 Subject: [PATCH] Removed unnecessary methods --- .../org/jboss/netty/channel/Channels.java | 24 ------------------- .../channel/DefaultWriteCompletionEvent.java | 8 ------- 2 files changed, 32 deletions(-) diff --git a/src/main/java/org/jboss/netty/channel/Channels.java b/src/main/java/org/jboss/netty/channel/Channels.java index 23c5ec90ab..c5ee8584fc 100644 --- a/src/main/java/org/jboss/netty/channel/Channels.java +++ b/src/main/java/org/jboss/netty/channel/Channels.java @@ -303,20 +303,6 @@ public class Channels { ctx.getChannel(), message, remoteAddress)); } - /** - * Sends a {@code "writeComplete"} event to the first - * {@link ChannelUpstreamHandler} in the {@link ChannelPipeline} of - * the specified {@link Channel}. - */ - public static void fireWriteComplete(Channel channel, int amount) { - if (amount == 0) { - return; - } - - channel.getPipeline().sendUpstream( - new DefaultWriteCompletionEvent(channel, (long) amount)); - } - /** * Sends a {@code "writeComplete"} event to the first * {@link ChannelUpstreamHandler} in the {@link ChannelPipeline} of @@ -331,16 +317,6 @@ public class Channels { new DefaultWriteCompletionEvent(channel, amount)); } - /** - * Sends a {@code "writeComplete"} event to the - * {@link ChannelUpstreamHandler} which is placed in the closest upstream - * from the handler associated with the specified - * {@link ChannelHandlerContext}. - */ - public static void fireWriteComplete(ChannelHandlerContext ctx, int amount) { - ctx.sendUpstream(new DefaultWriteCompletionEvent(ctx.getChannel(), (long) amount)); - } - /** * Sends a {@code "writeComplete"} event to the * {@link ChannelUpstreamHandler} which is placed in the closest upstream diff --git a/src/main/java/org/jboss/netty/channel/DefaultWriteCompletionEvent.java b/src/main/java/org/jboss/netty/channel/DefaultWriteCompletionEvent.java index 96d948e1a1..846e07f0f4 100644 --- a/src/main/java/org/jboss/netty/channel/DefaultWriteCompletionEvent.java +++ b/src/main/java/org/jboss/netty/channel/DefaultWriteCompletionEvent.java @@ -30,14 +30,6 @@ public class DefaultWriteCompletionEvent implements WriteCompletionEvent { private final Channel channel; private final long writtenAmount; - /** - * @deprecated Use {@link #DefaultWriteCompletionEvent(Channel, long)} instead. - */ - @Deprecated - public DefaultWriteCompletionEvent(Channel channel, int writtenAmount) { - this(channel, (long) writtenAmount); - } - /** * Creates a new instance. */