Fix some inspector warnings

This commit is contained in:
Trustin Lee 2013-11-04 17:50:40 +09:00
parent eadf5b3d10
commit cdf24a161c
3 changed files with 5 additions and 6 deletions

View File

@ -42,6 +42,7 @@ import java.util.TreeMap;
/**
* This decoder will decode Body and can handle POST BODY in multipart form.
*/
@SuppressWarnings({ "deprecation", "RedundantThrowsDeclaration" })
public class HttpPostMultipartRequestDecoder implements InterfaceHttpPostRequestDecoder {
/**
* Factory used to create InterfaceHttpData
@ -176,9 +177,6 @@ public class HttpPostMultipartRequestDecoder implements InterfaceHttpPostRequest
/**
* Set from the request ContentType the multipartDataBoundary.
* @param contentType
* @throws ErrorDataDecoderException
* @throws org.jboss.netty.handler.codec.http.multipart.HttpPostRequestDecoder.ErrorDataDecoderException
*/
private void setMultipart(String contentType) throws ErrorDataDecoderException {
multipartDataBoundary = HttpPostRequestDecoder.getMultipartDataBoundary(contentType);

View File

@ -27,11 +27,12 @@ import java.util.List;
/**
* This decoder will decode Body and can handle POST BODY (both multipart and standard).
*/
@SuppressWarnings("deprecation")
public class HttpPostRequestDecoder implements InterfaceHttpPostRequestDecoder {
/**
* Does this request is a Multipart request
*/
private InterfaceHttpPostRequestDecoder decoder;
private final InterfaceHttpPostRequestDecoder decoder;
/**
*
@ -144,9 +145,8 @@ public class HttpPostRequestDecoder implements InterfaceHttpPostRequestDecoder {
/**
* Check if the given request is a multipart request
* @param request
*
* @return True if the request is a Multipart request
* @throws ErrorDataDecoderException
*/
public static boolean isMultipart(HttpRequest request) throws ErrorDataDecoderException {
if (request.headers().contains(HttpHeaders.Names.CONTENT_TYPE)) {

View File

@ -41,6 +41,7 @@ import java.util.TreeMap;
/**
* This decoder will decode Body and can handle standard (non multipart) POST BODY.
*/
@SuppressWarnings({ "deprecation", "RedundantThrowsDeclaration" })
public class HttpPostStandardRequestDecoder implements InterfaceHttpPostRequestDecoder {
/**
* Factory used to create InterfaceHttpData