Remove various unnecessary qualifiers

This commit is contained in:
Trustin Lee 2012-11-10 07:03:07 +09:00
parent 5c57dd9f0d
commit 23883d25ee
17 changed files with 31 additions and 33 deletions

View File

@ -56,7 +56,7 @@ public enum HttpTransferEncoding {
private final boolean single;
private HttpTransferEncoding(boolean single) {
HttpTransferEncoding(boolean single) {
this.single = single;
}

View File

@ -25,7 +25,6 @@ public final class CaseIgnoringComparator implements Comparator<String>, Seriali
public static final CaseIgnoringComparator INSTANCE = new CaseIgnoringComparator();
private CaseIgnoringComparator() {
super();
}
@Override

View File

@ -39,7 +39,7 @@ import io.netty.handler.ssl.SslHandler;
*/
public abstract class SpdyOrHttpChooser extends ChannelHandlerAdapter implements ChannelInboundByteHandler {
public static enum SelectedProtocol {
public enum SelectedProtocol {
SpdyVersion2,
SpdyVersion3,
HttpVersion1_1,

View File

@ -76,17 +76,17 @@ public class WebSocketRequestBuilder {
}
public WebSocketRequestBuilder version13() {
this.version = WebSocketVersion.V13;
version = WebSocketVersion.V13;
return this;
}
public WebSocketRequestBuilder version8() {
this.version = WebSocketVersion.V08;
version = WebSocketVersion.V08;
return this;
}
public WebSocketRequestBuilder version00() {
this.version = null;
version = null;
return this;
}

View File

@ -139,7 +139,7 @@ public final class MonitorName {
if (instance.equals(this.instance)) {
return this;
}
return new MonitorName(this.group, this.type, this.name, instance);
return new MonitorName(group, type, name, instance);
}
/**
@ -251,7 +251,7 @@ public final class MonitorName {
*/
@Override
public String toString() {
return this.instance != null ? "Monitor(" + group + "/" + type + "/" + name + "/" + instance + ")" : "Monitor("
return instance != null ? "Monitor(" + group + "/" + type + "/" + name + "/" + instance + ")" : "Monitor("
+ group + "/" + type + "/" + name + ")";
}
}

View File

@ -127,12 +127,12 @@ public final class MonitorRegistries implements Iterable<MonitorRegistry> {
@Override
public boolean hasNext() {
return this.factories.hasNext();
return factories.hasNext();
}
@Override
public MonitorRegistry next() {
return this.factories.next().newMonitorRegistry();
return factories.next().newMonitorRegistry();
}
@Override

View File

@ -63,7 +63,7 @@ public final class MonitorProvider implements Serializable, Comparable<MonitorPr
*/
@Override
public int compareTo(final MonitorProvider o) {
return this.name.compareTo(o.name);
return name.compareTo(o.name);
}
/**

View File

@ -63,12 +63,12 @@ public class HashedWheelTimerMonitorTest {
@Override
public ValueDistributionMonitor newValueDistributionMonitor(final MonitorName monitorName) {
return this.eventDistributionMonitor;
return eventDistributionMonitor;
}
@Override
public EventRateMonitor newEventRateMonitor(final MonitorName monitorName, final TimeUnit rateUnit) {
return this.eventRateMonitor;
return eventRateMonitor;
}
@Override

View File

@ -44,7 +44,7 @@ class YammerCounterMonitor implements CounterMonitor {
*/
@Override
public void inc() {
this.delegate.inc();
delegate.inc();
}
/**
@ -52,7 +52,7 @@ class YammerCounterMonitor implements CounterMonitor {
*/
@Override
public void inc(final long delta) {
this.delegate.inc(delta);
delegate.inc(delta);
}
/**
@ -60,7 +60,7 @@ class YammerCounterMonitor implements CounterMonitor {
*/
@Override
public void decr() {
this.delegate.dec();
delegate.dec();
}
/**
@ -68,7 +68,7 @@ class YammerCounterMonitor implements CounterMonitor {
*/
@Override
public void decr(final long delta) {
this.delegate.dec(delta);
delegate.dec(delta);
}
/**
@ -76,7 +76,7 @@ class YammerCounterMonitor implements CounterMonitor {
*/
@Override
public void reset() {
this.delegate.clear();
delegate.clear();
}
/**

View File

@ -45,7 +45,7 @@ class YammerEventRateMonitor implements EventRateMonitor {
*/
@Override
public void event() {
this.delegate.mark();
delegate.mark();
}
/**
@ -54,7 +54,7 @@ class YammerEventRateMonitor implements EventRateMonitor {
*/
@Override
public void events(final long count) {
this.delegate.mark(count);
delegate.mark(count);
}
/**

View File

@ -68,7 +68,7 @@ public final class YammerMonitorRegistry implements MonitorRegistry {
*/
@Override
public ValueDistributionMonitor newValueDistributionMonitor(final MonitorName monitorName) {
final Histogram histogram = this.delegate.newHistogram(Utils.toMetricName(monitorName), true);
final Histogram histogram = delegate.newHistogram(Utils.toMetricName(monitorName), true);
return new YammerValueDistributionMonitor(histogram);
}
@ -80,7 +80,7 @@ public final class YammerMonitorRegistry implements MonitorRegistry {
*/
@Override
public EventRateMonitor newEventRateMonitor(final MonitorName monitorName, final TimeUnit rateUnit) {
final Meter meter = this.delegate.newMeter(Utils.toMetricName(monitorName), monitorName.getName(), rateUnit);
final Meter meter = delegate.newMeter(Utils.toMetricName(monitorName), monitorName.getName(), rateUnit);
return new YammerEventRateMonitor(meter);
}
@ -92,7 +92,7 @@ public final class YammerMonitorRegistry implements MonitorRegistry {
*/
@Override
public <T> ValueMonitor<T> registerValueMonitor(final MonitorName monitorName, final ValueMonitor<T> valueMonitor) {
this.delegate.newGauge(Utils.toMetricName(monitorName), new Gauge<T>() {
delegate.newGauge(Utils.toMetricName(monitorName), new Gauge<T>() {
@Override
public T value() {
return valueMonitor.currentValue();
@ -108,7 +108,7 @@ public final class YammerMonitorRegistry implements MonitorRegistry {
*/
@Override
public CounterMonitor newCounterMonitor(MonitorName monitorName) {
final Counter counter = this.delegate.newCounter(Utils.toMetricName(monitorName));
final Counter counter = delegate.newCounter(Utils.toMetricName(monitorName));
return new YammerCounterMonitor(counter);
}

View File

@ -44,7 +44,7 @@ final class YammerValueDistributionMonitor implements ValueDistributionMonitor {
*/
@Override
public void reset() {
this.delegate.clear();
delegate.clear();
}
/**
@ -52,7 +52,7 @@ final class YammerValueDistributionMonitor implements ValueDistributionMonitor {
*/
@Override
public void update(final long value) {
this.delegate.update(value);
delegate.update(value);
}
/**

View File

@ -24,7 +24,6 @@ public class UnsupportedOperatingSystemException extends RuntimeException {
}
public UnsupportedOperatingSystemException() {
super();
}
public UnsupportedOperatingSystemException(String message) {

View File

@ -45,8 +45,8 @@ public final class SctpMessage {
public SctpMessage(MessageInfo msgInfo, ByteBuf payloadBuffer) {
this.msgInfo = msgInfo;
this.streamIdentifier = msgInfo.streamNumber();
this.protocolIdentifier = msgInfo.payloadProtocolID();
streamIdentifier = msgInfo.streamNumber();
protocolIdentifier = msgInfo.payloadProtocolID();
this.payloadBuffer = payloadBuffer;
}

View File

@ -68,7 +68,7 @@ public class AioSocketChannel extends AbstractAioChannel implements SocketChanne
private final Runnable readTask = new Runnable() {
@Override
public void run() {
AioSocketChannel.this.beginRead();
beginRead();
}
};

View File

@ -132,7 +132,7 @@ public final class NioEventLoop extends SingleThreadEventLoop {
// selector to the new one
private Selector recreateSelector() {
final Selector newSelector = openSelector();
final Selector oldSelector = this.selector;
final Selector oldSelector = selector;
// Register all channels to the new Selector.
boolean success = false;
@ -166,7 +166,7 @@ public final class NioEventLoop extends SingleThreadEventLoop {
}
logger.info("Selector migration complete.");
return this.selector = newSelector;
return selector = newSelector;
}
@Override

View File

@ -49,7 +49,7 @@ public class NioSctpServerChannel extends AbstractNioMessageChannel
public NioSctpServerChannel() {
super(null, null, newSocket(), SelectionKey.OP_ACCEPT);
config = new DefaultSctpServerChannelConfig(this.javaChannel());
config = new DefaultSctpServerChannelConfig(javaChannel());
}
@Override