Top Description Fields Constructors Methods
org.glassfish.grizzly.http.util

public final Class UDecoder

extends Object
Class Inheritance
Imports
java.io.CharConversionException, .IOException

All URL decoding happens here. This way we can reuse, review, optimize without adding complexity to the buffers. The conversion will modify the original buffer.
Author
Costin Manolache

Field Summary

Modifier and TypeField and Description
public static final boolean
private static final String
private boolean

Constructor Summary

AccessConstructor and Description
public
public
UDecoder(boolean allowEncodedSlash)

Method Summary

Modifier and TypeMethod and Description
public void
convert(ByteChunk mb)

URLDecode, will modify the source.

public void
convert(ByteChunk mb, boolean query)

URLDecode the ByteChunk

public static void
convert(ByteChunk mb, boolean query, boolean allowEncodedSlash)

URLDecode the ByteChunk

public void
convert(CharChunk mb)

In-buffer processing - the buffer will be modified Includes converting '+' to ' '.

public static void
convert(CharChunk mb, boolean query)

In-buffer processing - the buffer will be modified

public void
convert(MessageBytes mb)

URLDecode, will modify the source Includes converting '+' to ' '.

public void
convert(MessageBytes mb, boolean query)

URLDecode, will modify the source

public static void
convert(MessageBytes mb, boolean query, boolean allowEncodingSlash)

URLDecode, will modify the source

public static String
public static String
convert(String str, boolean query)

public boolean
private static boolean
isHexDigit(int c)

public void
setAllowEncodedSlash(boolean allowEncodedSlash)

Override the default value

private static int
x2c(byte b1, byte b2)

private static int
x2c(char b1, char b2)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

ALLOW_ENCODED_SLASHback to summary
public static final boolean ALLOW_ENCODED_SLASH
ALLOW_ENCODED_SLASH_NAMEback to summary
private static final String ALLOW_ENCODED_SLASH_NAME
allowEncodedSlashback to summary
private boolean allowEncodedSlash

Constructor Detail

UDecoderback to summary
public UDecoder()
UDecoderback to summary
public UDecoder(boolean allowEncodedSlash)

Method Detail

convertback to summary
public void convert(ByteChunk mb) throws IOException

URLDecode, will modify the source. Includes converting '+' to ' '.

convertback to summary
public void convert(ByteChunk mb, boolean query) throws IOException

URLDecode the ByteChunk

convertback to summary
public static void convert(ByteChunk mb, boolean query, boolean allowEncodedSlash) throws IOException

URLDecode the ByteChunk

convertback to summary
public void convert(CharChunk mb) throws IOException

In-buffer processing - the buffer will be modified Includes converting '+' to ' '.

convertback to summary
public static void convert(CharChunk mb, boolean query) throws IOException

In-buffer processing - the buffer will be modified

convertback to summary
public void convert(MessageBytes mb) throws IOException

URLDecode, will modify the source Includes converting '+' to ' '.

convertback to summary
public void convert(MessageBytes mb, boolean query) throws IOException

URLDecode, will modify the source

convertback to summary
public static void convert(MessageBytes mb, boolean query, boolean allowEncodingSlash) throws IOException

URLDecode, will modify the source

convertback to summary
public static String convert(String str)
convertback to summary
public static String convert(String str, boolean query)
isAllowEncodedSlashback to summary
public boolean isAllowEncodedSlash()
isHexDigitback to summary
private static boolean isHexDigit(int c)
setAllowEncodedSlashback to summary
public void setAllowEncodedSlash(boolean allowEncodedSlash)

Override the default value

x2cback to summary
private static int x2c(byte b1, byte b2)
x2cback to summary
private static int x2c(char b1, char b2)