You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mina.apache.org by el...@apache.org on 2015/12/25 06:37:24 UTC
mina git commit: Removed redundant modifiers
Repository: mina
Updated Branches:
refs/heads/2.0 5751d2bc8 -> 7f2edfb98
Removed redundant modifiers
Project: http://git-wip-us.apache.org/repos/asf/mina/repo
Commit: http://git-wip-us.apache.org/repos/asf/mina/commit/7f2edfb9
Tree: http://git-wip-us.apache.org/repos/asf/mina/tree/7f2edfb9
Diff: http://git-wip-us.apache.org/repos/asf/mina/diff/7f2edfb9
Branch: refs/heads/2.0
Commit: 7f2edfb98058a3c284ccfea58e99df0f8bc8fa41
Parents: 5751d2b
Author: Emmanuel Lécharny <el...@symas.com>
Authored: Fri Dec 25 06:24:45 2015 +0100
Committer: Emmanuel Lécharny <el...@symas.com>
Committed: Fri Dec 25 06:24:45 2015 +0100
----------------------------------------------------------------------
.../apache/mina/core/filterchain/IoFilter.java | 2 +-
.../mina/core/filterchain/IoFilterChain.java | 22 ++---
.../mina/core/future/IoFutureListener.java | 2 +-
.../mina/core/session/IoSessionRecycler.java | 2 +-
.../mina/filter/codec/demux/MessageDecoder.java | 6 +-
.../filter/executor/IoEventQueueHandler.java | 2 +-
.../KeepAliveRequestTimeoutHandler.java | 10 +--
.../mina/handler/chain/IoHandlerCommand.java | 2 +-
.../mina/handler/demux/ExceptionHandler.java | 4 +-
.../mina/handler/demux/MessageHandler.java | 2 +-
.../apache/mina/proxy/ProxyLogicHandler.java | 10 +--
.../proxy/handlers/http/ntlm/NTLMConstants.java | 89 ++++++++++----------
.../mina/transport/socket/SocketAcceptor.java | 8 +-
.../socket/nio/NioDatagramAcceptor.java | 4 +-
.../apache/mina/util/byteaccess/ByteArray.java | 7 +-
.../mina/util/byteaccess/IoAbsoluteReader.java | 2 +-
.../mina/util/byteaccess/IoAbsoluteWriter.java | 2 +-
.../org/apache/mina/http/api/HttpMessage.java | 12 +--
.../org/apache/mina/http/api/HttpResponse.java | 3 +-
19 files changed, 94 insertions(+), 97 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/core/filterchain/IoFilter.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/core/filterchain/IoFilter.java b/mina-core/src/main/java/org/apache/mina/core/filterchain/IoFilter.java
index fdd64fe..14e21af 100644
--- a/mina-core/src/main/java/org/apache/mina/core/filterchain/IoFilter.java
+++ b/mina-core/src/main/java/org/apache/mina/core/filterchain/IoFilter.java
@@ -273,7 +273,7 @@ public interface IoFilter {
/**
* Represents the next {@link IoFilter} in {@link IoFilterChain}.
*/
- public interface NextFilter {
+ interface NextFilter {
/**
* Forwards <tt>sessionCreated</tt> event to next filter.
*
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/core/filterchain/IoFilterChain.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/core/filterchain/IoFilterChain.java b/mina-core/src/main/java/org/apache/mina/core/filterchain/IoFilterChain.java
index 4dd01ea..4814025 100644
--- a/mina-core/src/main/java/org/apache/mina/core/filterchain/IoFilterChain.java
+++ b/mina-core/src/main/java/org/apache/mina/core/filterchain/IoFilterChain.java
@@ -252,21 +252,21 @@ public interface IoFilterChain {
* call this method at all. Please use this method only when you implement a new transport
* or fire a virtual event.
*/
- public void fireSessionCreated();
+ void fireSessionCreated();
/**
* Fires a {@link IoHandler#sessionOpened(IoSession)} event. Most users don't need to call
* this method at all. Please use this method only when you implement a new transport or
* fire a virtual event.
*/
- public void fireSessionOpened();
+ void fireSessionOpened();
/**
* Fires a {@link IoHandler#sessionClosed(IoSession)} event. Most users don't need to call
* this method at all. Please use this method only when you implement a new transport or
* fire a virtual event.
*/
- public void fireSessionClosed();
+ void fireSessionClosed();
/**
* Fires a {@link IoHandler#sessionIdle(IoSession, IdleStatus)} event. Most users don't
@@ -275,7 +275,7 @@ public interface IoFilterChain {
*
* @param status The current status to propagate
*/
- public void fireSessionIdle(IdleStatus status);
+ void fireSessionIdle(IdleStatus status);
/**
* Fires a {@link IoHandler#messageReceived(IoSession, Object)} event. Most
@@ -285,7 +285,7 @@ public interface IoFilterChain {
* @param message
* The received message
*/
- public void fireMessageReceived(Object message);
+ void fireMessageReceived(Object message);
/**
* Fires a {@link IoHandler#messageSent(IoSession, Object)} event. Most
@@ -295,7 +295,7 @@ public interface IoFilterChain {
* @param request
* The sent request
*/
- public void fireMessageSent(WriteRequest request);
+ void fireMessageSent(WriteRequest request);
/**
* Fires a {@link IoHandler#exceptionCaught(IoSession, Throwable)} event. Most users don't
@@ -304,14 +304,14 @@ public interface IoFilterChain {
*
* @param cause The exception cause
*/
- public void fireExceptionCaught(Throwable cause);
+ void fireExceptionCaught(Throwable cause);
/**
* Fires a {@link IoHandler#inputClosed(IoSession)} event. Most users don't
* need to call this method at all. Please use this method only when you
* implement a new transport or fire a virtual event.
*/
- public void fireInputClosed();
+ void fireInputClosed();
/**
* Fires a {@link IoSession#write(Object)} event. Most users don't need to
@@ -321,21 +321,21 @@ public interface IoFilterChain {
* @param writeRequest
* The message to write
*/
- public void fireFilterWrite(WriteRequest writeRequest);
+ void fireFilterWrite(WriteRequest writeRequest);
/**
* Fires a {@link IoSession#close(boolean)} event. Most users don't need to call this method at
* all. Please use this method only when you implement a new transport or fire a virtual
* event.
*/
- public void fireFilterClose();
+ void fireFilterClose();
/**
* Represents a name-filter pair that an {@link IoFilterChain} contains.
*
* @author <a href="http://mina.apache.org">Apache MINA Project</a>
*/
- public interface Entry {
+ interface Entry {
/**
* @return the name of the filter.
*/
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/core/future/IoFutureListener.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/core/future/IoFutureListener.java b/mina-core/src/main/java/org/apache/mina/core/future/IoFutureListener.java
index 4963a37..d0c71e7 100644
--- a/mina-core/src/main/java/org/apache/mina/core/future/IoFutureListener.java
+++ b/mina-core/src/main/java/org/apache/mina/core/future/IoFutureListener.java
@@ -34,7 +34,7 @@ public interface IoFutureListener<F extends IoFuture> extends EventListener {
* An {@link IoFutureListener} that closes the {@link IoSession} which is
* associated with the specified {@link IoFuture}.
*/
- static IoFutureListener<IoFuture> CLOSE = new IoFutureListener<IoFuture>() {
+ IoFutureListener<IoFuture> CLOSE = new IoFutureListener<IoFuture>() {
public void operationComplete(IoFuture future) {
future.getSession().close(true);
}
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/core/session/IoSessionRecycler.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/core/session/IoSessionRecycler.java b/mina-core/src/main/java/org/apache/mina/core/session/IoSessionRecycler.java
index d10d0d7..55d7dcd 100644
--- a/mina-core/src/main/java/org/apache/mina/core/session/IoSessionRecycler.java
+++ b/mina-core/src/main/java/org/apache/mina/core/session/IoSessionRecycler.java
@@ -36,7 +36,7 @@ public interface IoSessionRecycler {
* make all session lifecycle events to be fired for every I/O for all connectionless
* sessions.
*/
- static IoSessionRecycler NOOP = new IoSessionRecycler() {
+ IoSessionRecycler NOOP = new IoSessionRecycler() {
/**
* {@inheritDoc}
*/
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/filter/codec/demux/MessageDecoder.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/filter/codec/demux/MessageDecoder.java b/mina-core/src/main/java/org/apache/mina/filter/codec/demux/MessageDecoder.java
index 09e714d..0f2ad70 100644
--- a/mina-core/src/main/java/org/apache/mina/filter/codec/demux/MessageDecoder.java
+++ b/mina-core/src/main/java/org/apache/mina/filter/codec/demux/MessageDecoder.java
@@ -41,21 +41,21 @@ public interface MessageDecoder {
* {@link #decode(IoSession, IoBuffer, ProtocolDecoderOutput)}. Please
* refer to each method's documentation for detailed explanation.
*/
- static MessageDecoderResult OK = MessageDecoderResult.OK;
+ MessageDecoderResult OK = MessageDecoderResult.OK;
/**
* Represents a result from {@link #decodable(IoSession, IoBuffer)} and
* {@link #decode(IoSession, IoBuffer, ProtocolDecoderOutput)}. Please
* refer to each method's documentation for detailed explanation.
*/
- static MessageDecoderResult NEED_DATA = MessageDecoderResult.NEED_DATA;
+ MessageDecoderResult NEED_DATA = MessageDecoderResult.NEED_DATA;
/**
* Represents a result from {@link #decodable(IoSession, IoBuffer)} and
* {@link #decode(IoSession, IoBuffer, ProtocolDecoderOutput)}. Please
* refer to each method's documentation for detailed explanation.
*/
- static MessageDecoderResult NOT_OK = MessageDecoderResult.NOT_OK;
+ MessageDecoderResult NOT_OK = MessageDecoderResult.NOT_OK;
/**
* Checks the specified buffer is decodable by this decoder.
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/filter/executor/IoEventQueueHandler.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/filter/executor/IoEventQueueHandler.java b/mina-core/src/main/java/org/apache/mina/filter/executor/IoEventQueueHandler.java
index 7338129..76326f0 100644
--- a/mina-core/src/main/java/org/apache/mina/filter/executor/IoEventQueueHandler.java
+++ b/mina-core/src/main/java/org/apache/mina/filter/executor/IoEventQueueHandler.java
@@ -34,7 +34,7 @@ public interface IoEventQueueHandler extends EventListener {
/**
* A dummy handler which always accepts event doing nothing particular.
*/
- static IoEventQueueHandler NOOP = new IoEventQueueHandler() {
+ IoEventQueueHandler NOOP = new IoEventQueueHandler() {
public boolean accept(Object source, IoEvent event) {
return true;
}
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/filter/keepalive/KeepAliveRequestTimeoutHandler.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/filter/keepalive/KeepAliveRequestTimeoutHandler.java b/mina-core/src/main/java/org/apache/mina/filter/keepalive/KeepAliveRequestTimeoutHandler.java
index 22e002b..5d2ba8a 100644
--- a/mina-core/src/main/java/org/apache/mina/filter/keepalive/KeepAliveRequestTimeoutHandler.java
+++ b/mina-core/src/main/java/org/apache/mina/filter/keepalive/KeepAliveRequestTimeoutHandler.java
@@ -33,7 +33,7 @@ public interface KeepAliveRequestTimeoutHandler {
/**
* Do nothing.
*/
- static KeepAliveRequestTimeoutHandler NOOP = new KeepAliveRequestTimeoutHandler() {
+ KeepAliveRequestTimeoutHandler NOOP = new KeepAliveRequestTimeoutHandler() {
public void keepAliveRequestTimedOut(KeepAliveFilter filter, IoSession session) throws Exception {
// Do nothing.
}
@@ -42,7 +42,7 @@ public interface KeepAliveRequestTimeoutHandler {
/**
* Logs a warning message, but doesn't do anything else.
*/
- static KeepAliveRequestTimeoutHandler LOG = new KeepAliveRequestTimeoutHandler() {
+ KeepAliveRequestTimeoutHandler LOG = new KeepAliveRequestTimeoutHandler() {
private final Logger LOGGER = LoggerFactory.getLogger(KeepAliveFilter.class);
public void keepAliveRequestTimedOut(KeepAliveFilter filter, IoSession session) throws Exception {
@@ -54,7 +54,7 @@ public interface KeepAliveRequestTimeoutHandler {
/**
* Throws a {@link KeepAliveRequestTimeoutException}.
*/
- static KeepAliveRequestTimeoutHandler EXCEPTION = new KeepAliveRequestTimeoutHandler() {
+ KeepAliveRequestTimeoutHandler EXCEPTION = new KeepAliveRequestTimeoutHandler() {
public void keepAliveRequestTimedOut(KeepAliveFilter filter, IoSession session) throws Exception {
throw new KeepAliveRequestTimeoutException("A keep-alive response message was not received within "
+ filter.getRequestTimeout() + " second(s).");
@@ -64,7 +64,7 @@ public interface KeepAliveRequestTimeoutHandler {
/**
* Closes the connection after logging.
*/
- static KeepAliveRequestTimeoutHandler CLOSE = new KeepAliveRequestTimeoutHandler() {
+ KeepAliveRequestTimeoutHandler CLOSE = new KeepAliveRequestTimeoutHandler() {
private final Logger LOGGER = LoggerFactory.getLogger(KeepAliveFilter.class);
public void keepAliveRequestTimedOut(KeepAliveFilter filter, IoSession session) throws Exception {
@@ -77,7 +77,7 @@ public interface KeepAliveRequestTimeoutHandler {
/**
* A special handler for the 'deaf speaker' mode.
*/
- static KeepAliveRequestTimeoutHandler DEAF_SPEAKER = new KeepAliveRequestTimeoutHandler() {
+ KeepAliveRequestTimeoutHandler DEAF_SPEAKER = new KeepAliveRequestTimeoutHandler() {
public void keepAliveRequestTimedOut(KeepAliveFilter filter, IoSession session) throws Exception {
throw new Error("Shouldn't be invoked. Please file a bug report.");
}
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/handler/chain/IoHandlerCommand.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/handler/chain/IoHandlerCommand.java b/mina-core/src/main/java/org/apache/mina/handler/chain/IoHandlerCommand.java
index 700878e..b3a778e 100644
--- a/mina-core/src/main/java/org/apache/mina/handler/chain/IoHandlerCommand.java
+++ b/mina-core/src/main/java/org/apache/mina/handler/chain/IoHandlerCommand.java
@@ -82,7 +82,7 @@ public interface IoHandlerCommand {
*
* @author <a href="http://mina.apache.org">Apache MINA Project</a>
*/
- public interface NextCommand {
+ interface NextCommand {
/**
* Forwards the request to the next {@link IoHandlerCommand} in the
* {@link IoHandlerChain}.
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/handler/demux/ExceptionHandler.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/handler/demux/ExceptionHandler.java b/mina-core/src/main/java/org/apache/mina/handler/demux/ExceptionHandler.java
index 51992ab..cf80690 100644
--- a/mina-core/src/main/java/org/apache/mina/handler/demux/ExceptionHandler.java
+++ b/mina-core/src/main/java/org/apache/mina/handler/demux/ExceptionHandler.java
@@ -34,7 +34,7 @@ public interface ExceptionHandler<E extends Throwable> {
* A {@link ExceptionHandler} that does nothing. This is useful when
* you want to ignore an exception of a specific type silently.
*/
- static ExceptionHandler<Throwable> NOOP = new ExceptionHandler<Throwable>() {
+ ExceptionHandler<Throwable> NOOP = new ExceptionHandler<Throwable>() {
public void exceptionCaught(IoSession session, Throwable cause) {
// Do nothing
}
@@ -45,7 +45,7 @@ public interface ExceptionHandler<E extends Throwable> {
* This is useful when you want to close the session when an exception of
* a specific type is raised.
*/
- static ExceptionHandler<Throwable> CLOSE = new ExceptionHandler<Throwable>() {
+ ExceptionHandler<Throwable> CLOSE = new ExceptionHandler<Throwable>() {
public void exceptionCaught(IoSession session, Throwable cause) {
session.close(true);
}
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/handler/demux/MessageHandler.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/handler/demux/MessageHandler.java b/mina-core/src/main/java/org/apache/mina/handler/demux/MessageHandler.java
index b594100..d1a249f 100644
--- a/mina-core/src/main/java/org/apache/mina/handler/demux/MessageHandler.java
+++ b/mina-core/src/main/java/org/apache/mina/handler/demux/MessageHandler.java
@@ -35,7 +35,7 @@ public interface MessageHandler<E> {
* A {@link MessageHandler} that does nothing. This is useful when
* you want to ignore a message of a specific type silently.
*/
- static MessageHandler<Object> NOOP = new MessageHandler<Object>() {
+ MessageHandler<Object> NOOP = new MessageHandler<Object>() {
public void handleMessage(IoSession session, Object message) {
// Do nothing
}
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/proxy/ProxyLogicHandler.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/proxy/ProxyLogicHandler.java b/mina-core/src/main/java/org/apache/mina/proxy/ProxyLogicHandler.java
index 44a9a90..65681d8 100644
--- a/mina-core/src/main/java/org/apache/mina/proxy/ProxyLogicHandler.java
+++ b/mina-core/src/main/java/org/apache/mina/proxy/ProxyLogicHandler.java
@@ -37,7 +37,7 @@ public interface ProxyLogicHandler {
* @return <code>true</code> if handshaking is complete and
* data can be sent through the proxy, false otherwise.
*/
- public abstract boolean isHandshakeComplete();
+ boolean isHandshakeComplete();
/**
* Handle incoming data during the handshake process. Should consume only the
@@ -47,7 +47,7 @@ public interface ProxyLogicHandler {
* @param buf the buffer holding the received data
* @throws ProxyAuthException if authentication fails
*/
- public abstract void messageReceived(NextFilter nextFilter, IoBuffer buf) throws ProxyAuthException;
+ void messageReceived(NextFilter nextFilter, IoBuffer buf) throws ProxyAuthException;
/**
* Called at each step of the handshake procedure.
@@ -55,14 +55,14 @@ public interface ProxyLogicHandler {
* @param nextFilter the next filter in filter chain
* @throws ProxyAuthException if authentication fails
*/
- public abstract void doHandshake(NextFilter nextFilter) throws ProxyAuthException;
+ void doHandshake(NextFilter nextFilter) throws ProxyAuthException;
/**
* Returns the {@link ProxyIoSession}.
*
* @return the proxy session object
*/
- public abstract ProxyIoSession getProxyIoSession();
+ ProxyIoSession getProxyIoSession();
/**
* Enqueue a message to be written once handshaking is complete.
@@ -70,5 +70,5 @@ public interface ProxyLogicHandler {
* @param nextFilter the next filter in filter chain
* @param writeRequest the data to be written
*/
- public abstract void enqueueWriteRequest(final NextFilter nextFilter, final WriteRequest writeRequest);
+ void enqueueWriteRequest(final NextFilter nextFilter, final WriteRequest writeRequest);
}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/proxy/handlers/http/ntlm/NTLMConstants.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/proxy/handlers/http/ntlm/NTLMConstants.java b/mina-core/src/main/java/org/apache/mina/proxy/handlers/http/ntlm/NTLMConstants.java
index f451393..e067a3b 100644
--- a/mina-core/src/main/java/org/apache/mina/proxy/handlers/http/ntlm/NTLMConstants.java
+++ b/mina-core/src/main/java/org/apache/mina/proxy/handlers/http/ntlm/NTLMConstants.java
@@ -27,133 +27,132 @@ package org.apache.mina.proxy.handlers.http.ntlm;
*/
public interface NTLMConstants {
// Signature "NTLMSSP"+{0}
- public final static byte[] NTLM_SIGNATURE = new byte[] { 0x4E, 0x54, 0x4C, 0x4D, 0x53, 0x53, 0x50, 0 };
+ byte[] NTLM_SIGNATURE = new byte[] { 0x4E, 0x54, 0x4C, 0x4D, 0x53, 0x53, 0x50, 0 };
// Version 5.1.2600 a Windows XP version (ex: Build 2600.xpsp_sp2_gdr.050301-1519 : Service Pack 2)
- public final static byte[] DEFAULT_OS_VERSION = new byte[] { 0x05, 0x01, 0x28, 0x0A, 0, 0, 0, 0x0F };
+ byte[] DEFAULT_OS_VERSION = new byte[] { 0x05, 0x01, 0x28, 0x0A, 0, 0, 0, 0x0F };
/**
* Message types
*/
+ int MESSAGE_TYPE_1 = 1;
- public final static int MESSAGE_TYPE_1 = 1;
+ int MESSAGE_TYPE_2 = 2;
- public final static int MESSAGE_TYPE_2 = 2;
-
- public final static int MESSAGE_TYPE_3 = 3;
+ int MESSAGE_TYPE_3 = 3;
/**
* Message flags
*/
// Indicates that Unicode strings are supported for use in security buffer data
- public final static int FLAG_NEGOTIATE_UNICODE = 0x00000001;
+ int FLAG_NEGOTIATE_UNICODE = 0x00000001;
// Indicates that OEM strings are supported for use in security buffer data
- public final static int FLAG_NEGOTIATE_OEM = 0x00000002;
+ int FLAG_NEGOTIATE_OEM = 0x00000002;
// Requests that the server's authentication realm be included in the Type 2 message
- public final static int FLAG_REQUEST_SERVER_AUTH_REALM = 0x00000004;
+ int FLAG_REQUEST_SERVER_AUTH_REALM = 0x00000004;
// Specifies that authenticated communication between the client
// and server should carry a digital signature (message integrity)
- public final static int FLAG_NEGOTIATE_SIGN = 0x00000010;
+ int FLAG_NEGOTIATE_SIGN = 0x00000010;
// Specifies that authenticated communication between the client
// and server should be encrypted (message confidentiality)
- public final static int FLAG_NEGOTIATE_SEAL = 0x00000020;
+ int FLAG_NEGOTIATE_SEAL = 0x00000020;
// Indicates that datagram authentication is being used
- public final static int FLAG_NEGOTIATE_DATAGRAM_STYLE = 0x00000040;
+ int FLAG_NEGOTIATE_DATAGRAM_STYLE = 0x00000040;
// Indicates that the Lan Manager Session Key should be used for signing and
// sealing authenticated communications
- public final static int FLAG_NEGOTIATE_LAN_MANAGER_KEY = 0x00000080;
+ int FLAG_NEGOTIATE_LAN_MANAGER_KEY = 0x00000080;
// Indicates that NTLM authentication is being used
- public final static int FLAG_NEGOTIATE_NTLM = 0x00000200;
+ int FLAG_NEGOTIATE_NTLM = 0x00000200;
// Sent by the client in the Type 3 message to indicate that an anonymous context
// has been established. This also affects the response fields
- public final static int FLAG_NEGOTIATE_ANONYMOUS = 0x00000800;
+ int FLAG_NEGOTIATE_ANONYMOUS = 0x00000800;
// Sent by the client in the Type 1 message to indicate that the name of the domain in which
// the client workstation has membership is included in the message. This is used by the
// server to determine whether the client is eligible for local authentication
- public final static int FLAG_NEGOTIATE_DOMAIN_SUPPLIED = 0x00001000;
+ int FLAG_NEGOTIATE_DOMAIN_SUPPLIED = 0x00001000;
// Sent by the client in the Type 1 message to indicate that the client workstation's name
// is included in the message. This is used by the server to determine whether the client
// is eligible for local authentication
- public final static int FLAG_NEGOTIATE_WORKSTATION_SUPPLIED = 0x00002000;
+ int FLAG_NEGOTIATE_WORKSTATION_SUPPLIED = 0x00002000;
// Sent by the server to indicate that the server and client are on the same machine.
// Implies that the client may use the established local credentials for authentication
// instead of calculating a response to the challenge
- public final static int FLAG_NEGOTIATE_LOCAL_CALL = 0x00004000;
+ int FLAG_NEGOTIATE_LOCAL_CALL = 0x00004000;
// Indicates that authenticated communication between the client and server should
// be signed with a "dummy" signature
- public final static int FLAG_NEGOTIATE_ALWAYS_SIGN = 0x00008000;
+ int FLAG_NEGOTIATE_ALWAYS_SIGN = 0x00008000;
// Sent by the server in the Type 2 message to indicate that the target authentication
// realm is a domain
- public final static int FLAG_TARGET_TYPE_DOMAIN = 0x00010000;
+ int FLAG_TARGET_TYPE_DOMAIN = 0x00010000;
// Sent by the server in the Type 2 message to indicate that the target authentication
// realm is a server
- public final static int FLAG_TARGET_TYPE_SERVER = 0x00020000;
+ int FLAG_TARGET_TYPE_SERVER = 0x00020000;
// Sent by the server in the Type 2 message to indicate that the target authentication
// realm is a share. Presumably, this is for share-level authentication. Usage is unclear
- public final static int FLAG_TARGET_TYPE_SHARE = 0x00040000;
+ int FLAG_TARGET_TYPE_SHARE = 0x00040000;
// Indicates that the NTLM2 signing and sealing scheme should be used for protecting
// authenticated communications. Note that this refers to a particular session security
// scheme, and is not related to the use of NTLMv2 authentication. This flag can, however,
// have an effect on the response calculations
- public final static int FLAG_NEGOTIATE_NTLM2 = 0x00080000;
+ int FLAG_NEGOTIATE_NTLM2 = 0x00080000;
// Sent by the server in the Type 2 message to indicate that it is including a Target
// Information block in the message. The Target Information block is used in the
// calculation of the NTLMv2 response
- public final static int FLAG_NEGOTIATE_TARGET_INFO = 0x00800000;
+ int FLAG_NEGOTIATE_TARGET_INFO = 0x00800000;
// Indicates that 128-bit encryption is supported
- public final static int FLAG_NEGOTIATE_128_BIT_ENCRYPTION = 0x20000000;
+ int FLAG_NEGOTIATE_128_BIT_ENCRYPTION = 0x20000000;
// Indicates that the client will provide an encrypted master key in the "Session Key"
// field of the Type 3 message
- public final static int FLAG_NEGOTIATE_KEY_EXCHANGE = 0x40000000;
+ int FLAG_NEGOTIATE_KEY_EXCHANGE = 0x40000000;
// Indicates that 56-bit encryption is supported
- public final static int FLAG_NEGOTIATE_56_BIT_ENCRYPTION = 0x80000000;
+ int FLAG_NEGOTIATE_56_BIT_ENCRYPTION = 0x80000000;
// WARN : These flags usage has not been identified
- public final static int FLAG_UNIDENTIFIED_1 = 0x00000008;
+ int FLAG_UNIDENTIFIED_1 = 0x00000008;
- public final static int FLAG_UNIDENTIFIED_2 = 0x00000100; // Negotiate Netware ??!
+ int FLAG_UNIDENTIFIED_2 = 0x00000100; // Negotiate Netware ??!
- public final static int FLAG_UNIDENTIFIED_3 = 0x00000400;
+ int FLAG_UNIDENTIFIED_3 = 0x00000400;
- public final static int FLAG_UNIDENTIFIED_4 = 0x00100000; // Request Init Response ??!
+ int FLAG_UNIDENTIFIED_4 = 0x00100000; // Request Init Response ??!
- public final static int FLAG_UNIDENTIFIED_5 = 0x00200000; // Request Accept Response ??!
+ int FLAG_UNIDENTIFIED_5 = 0x00200000; // Request Accept Response ??!
- public final static int FLAG_UNIDENTIFIED_6 = 0x00400000; // Request Non-NT Session Key ??!
+ int FLAG_UNIDENTIFIED_6 = 0x00400000; // Request Non-NT Session Key ??!
- public final static int FLAG_UNIDENTIFIED_7 = 0x01000000;
+ int FLAG_UNIDENTIFIED_7 = 0x01000000;
- public final static int FLAG_UNIDENTIFIED_8 = 0x02000000;
+ int FLAG_UNIDENTIFIED_8 = 0x02000000;
- public final static int FLAG_UNIDENTIFIED_9 = 0x04000000;
+ int FLAG_UNIDENTIFIED_9 = 0x04000000;
- public final static int FLAG_UNIDENTIFIED_10 = 0x08000000;
+ int FLAG_UNIDENTIFIED_10 = 0x08000000;
- public final static int FLAG_UNIDENTIFIED_11 = 0x10000000;
+ int FLAG_UNIDENTIFIED_11 = 0x10000000;
// Default minimal flag set
- public final static int DEFAULT_FLAGS = FLAG_NEGOTIATE_OEM | FLAG_NEGOTIATE_UNICODE
+ int DEFAULT_FLAGS = FLAG_NEGOTIATE_OEM | FLAG_NEGOTIATE_UNICODE
| FLAG_NEGOTIATE_WORKSTATION_SUPPLIED | FLAG_NEGOTIATE_DOMAIN_SUPPLIED;
/**
@@ -162,20 +161,20 @@ public interface NTLMConstants {
*/
// Sub block terminator
- public final static short TARGET_INFORMATION_SUBBLOCK_TERMINATOR_TYPE = 0x0000;
+ short TARGET_INFORMATION_SUBBLOCK_TERMINATOR_TYPE = 0x0000;
// Server name
- public final static short TARGET_INFORMATION_SUBBLOCK_SERVER_TYPE = 0x0100;
+ short TARGET_INFORMATION_SUBBLOCK_SERVER_TYPE = 0x0100;
// Domain name
- public final static short TARGET_INFORMATION_SUBBLOCK_DOMAIN_TYPE = 0x0200;
+ short TARGET_INFORMATION_SUBBLOCK_DOMAIN_TYPE = 0x0200;
// Fully-qualified DNS host name (i.e., server.domain.com)
- public final static short TARGET_INFORMATION_SUBBLOCK_FQDNS_HOSTNAME_TYPE = 0x0300;
+ short TARGET_INFORMATION_SUBBLOCK_FQDNS_HOSTNAME_TYPE = 0x0300;
// DNS domain name (i.e., domain.com)
- public final static short TARGET_INFORMATION_SUBBLOCK_DNS_DOMAIN_NAME_TYPE = 0x0400;
+ short TARGET_INFORMATION_SUBBLOCK_DNS_DOMAIN_NAME_TYPE = 0x0400;
// Apparently the "parent" DNS domain for servers in sub domains
- public final static short TARGET_INFORMATION_SUBBLOCK_PARENT_DNS_DOMAIN_NAME_TYPE = 0x0500;
+ short TARGET_INFORMATION_SUBBLOCK_PARENT_DNS_DOMAIN_NAME_TYPE = 0x0500;
}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/transport/socket/SocketAcceptor.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/transport/socket/SocketAcceptor.java b/mina-core/src/main/java/org/apache/mina/transport/socket/SocketAcceptor.java
index 2b655b9..5825cf2 100644
--- a/mina-core/src/main/java/org/apache/mina/transport/socket/SocketAcceptor.java
+++ b/mina-core/src/main/java/org/apache/mina/transport/socket/SocketAcceptor.java
@@ -57,23 +57,23 @@ public interface SocketAcceptor extends IoAcceptor {
/**
* @see ServerSocket#getReuseAddress()
*/
- public boolean isReuseAddress();
+ boolean isReuseAddress();
/**
* @see ServerSocket#setReuseAddress(boolean)
*/
- public void setReuseAddress(boolean reuseAddress);
+ void setReuseAddress(boolean reuseAddress);
/**
* Returns the size of the backlog.
*/
- public int getBacklog();
+ int getBacklog();
/**
* Sets the size of the backlog. This can only be done when this
* class is not bound
*/
- public void setBacklog(int backlog);
+ void setBacklog(int backlog);
/**
* Returns the default configuration of the new SocketSessions created by
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/transport/socket/nio/NioDatagramAcceptor.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/transport/socket/nio/NioDatagramAcceptor.java b/mina-core/src/main/java/org/apache/mina/transport/socket/nio/NioDatagramAcceptor.java
index 411f9ec..64bdee2 100644
--- a/mina-core/src/main/java/org/apache/mina/transport/socket/nio/NioDatagramAcceptor.java
+++ b/mina-core/src/main/java/org/apache/mina/transport/socket/nio/NioDatagramAcceptor.java
@@ -263,11 +263,11 @@ public final class NioDatagramAcceptor extends AbstractIoAcceptor implements Dat
iterator.remove();
try {
- if ((key != null) && key.isValid() && key.isReadable()) {
+ if (key.isValid() && key.isReadable()) {
readHandle(handle);
}
- if ((key != null) && key.isValid() && key.isWritable()) {
+ if (key.isValid() && key.isWritable()) {
for (IoSession session : getManagedSessions().values()) {
scheduleFlush((NioSession) session);
}
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/util/byteaccess/ByteArray.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/util/byteaccess/ByteArray.java b/mina-core/src/main/java/org/apache/mina/util/byteaccess/ByteArray.java
index 742b4b5..5753ad5 100644
--- a/mina-core/src/main/java/org/apache/mina/util/byteaccess/ByteArray.java
+++ b/mina-core/src/main/java/org/apache/mina/util/byteaccess/ByteArray.java
@@ -77,7 +77,7 @@ public interface ByteArray extends IoAbsoluteReader, IoAbsoluteWriter {
* same index, have the same byte order, and contain the same bytes at each
* index.
*/
- public boolean equals(Object other);
+ boolean equals(Object other);
/**
* {@inheritDoc}
@@ -87,7 +87,7 @@ public interface ByteArray extends IoAbsoluteReader, IoAbsoluteWriter {
/**
* {@inheritDoc}
*/
- public void get(int index, IoBuffer bb);
+ void get(int index, IoBuffer bb);
/**
* {@inheritDoc}
@@ -112,7 +112,7 @@ public interface ByteArray extends IoAbsoluteReader, IoAbsoluteWriter {
* Should this be <code>Cloneable</code> to allow cheap mark/position
* emulation?
*/
- public interface Cursor extends IoRelativeReader, IoRelativeWriter {
+ interface Cursor extends IoRelativeReader, IoRelativeWriter {
/**
* Gets the current index of the cursor.
@@ -150,5 +150,4 @@ public interface ByteArray extends IoAbsoluteReader, IoAbsoluteWriter {
*/
int getInt();
}
-
}
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/util/byteaccess/IoAbsoluteReader.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/util/byteaccess/IoAbsoluteReader.java b/mina-core/src/main/java/org/apache/mina/util/byteaccess/IoAbsoluteReader.java
index 001734b..2c76c70 100644
--- a/mina-core/src/main/java/org/apache/mina/util/byteaccess/IoAbsoluteReader.java
+++ b/mina-core/src/main/java/org/apache/mina/util/byteaccess/IoAbsoluteReader.java
@@ -63,7 +63,7 @@ public interface IoAbsoluteReader {
/**
* Gets enough bytes to fill the <code>IoBuffer</code> from the given index.
*/
- public void get(int index, IoBuffer bb);
+ void get(int index, IoBuffer bb);
/**
* Gets a <code>short</code> from the given index.
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-core/src/main/java/org/apache/mina/util/byteaccess/IoAbsoluteWriter.java
----------------------------------------------------------------------
diff --git a/mina-core/src/main/java/org/apache/mina/util/byteaccess/IoAbsoluteWriter.java b/mina-core/src/main/java/org/apache/mina/util/byteaccess/IoAbsoluteWriter.java
index b5a582c..cfaa379 100644
--- a/mina-core/src/main/java/org/apache/mina/util/byteaccess/IoAbsoluteWriter.java
+++ b/mina-core/src/main/java/org/apache/mina/util/byteaccess/IoAbsoluteWriter.java
@@ -53,7 +53,7 @@ public interface IoAbsoluteWriter {
/**
* Puts bytes from the <code>IoBuffer</code> at the given index.
*/
- public void put(int index, IoBuffer bb);
+ void put(int index, IoBuffer bb);
/**
* Puts a <code>short</code> at the given index.
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-http/src/main/java/org/apache/mina/http/api/HttpMessage.java
----------------------------------------------------------------------
diff --git a/mina-http/src/main/java/org/apache/mina/http/api/HttpMessage.java b/mina-http/src/main/java/org/apache/mina/http/api/HttpMessage.java
index a995499..0de11b9 100644
--- a/mina-http/src/main/java/org/apache/mina/http/api/HttpMessage.java
+++ b/mina-http/src/main/java/org/apache/mina/http/api/HttpMessage.java
@@ -34,19 +34,19 @@ public interface HttpMessage {
*
* @return HTTP/1.0 or HTTP/1.1
*/
- public HttpVersion getProtocolVersion();
+ HttpVersion getProtocolVersion();
/**
* Gets the <tt>Content-Type</tt> header of the message.
*
* @return The content type.
*/
- public String getContentType();
+ String getContentType();
/**
* Returns <tt>true</tt> if this message enables keep-alive connection.
*/
- public boolean isKeepAlive();
+ boolean isKeepAlive();
/**
* Returns the value of the HTTP header with the specified name. If more than one header with the given name is
@@ -55,16 +55,16 @@ public interface HttpMessage {
* @param name The name of the desired header
* @return The header value - or null if no header is found with the specified name
*/
- public String getHeader(String name);
+ String getHeader(String name);
/**
* Returns <tt>true</tt> if the HTTP header with the specified name exists in this request.
*/
- public boolean containsHeader(String name);
+ boolean containsHeader(String name);
/**
* Returns a read-only {@link Map} of HTTP headers whose key is a {@link String} and whose value is a {@link String}
* s.
*/
- public Map<String, String> getHeaders();
+ Map<String, String> getHeaders();
}
http://git-wip-us.apache.org/repos/asf/mina/blob/7f2edfb9/mina-http/src/main/java/org/apache/mina/http/api/HttpResponse.java
----------------------------------------------------------------------
diff --git a/mina-http/src/main/java/org/apache/mina/http/api/HttpResponse.java b/mina-http/src/main/java/org/apache/mina/http/api/HttpResponse.java
index ac2feca..cea28a0 100644
--- a/mina-http/src/main/java/org/apache/mina/http/api/HttpResponse.java
+++ b/mina-http/src/main/java/org/apache/mina/http/api/HttpResponse.java
@@ -31,6 +31,5 @@ public interface HttpResponse extends HttpMessage {
*
* @return the status of the HTTP response
*/
- public HttpStatus getStatus();
-
+ HttpStatus getStatus();
}