at.molindo.utils.tools
Enum URLCoder
java.lang.Object
java.lang.Enum<URLCoder>
at.molindo.utils.tools.URLCoder
- All Implemented Interfaces:
- Serializable, Comparable<URLCoder>
public enum URLCoder
- extends Enum<URLCoder>
wrapper around UriUtils.encode*(..) methods
- Author:
- stf@molindo.at
SCHEME
public static final URLCoder SCHEME
USER_INFO
public static final URLCoder USER_INFO
HOST
public static final URLCoder HOST
PORT
public static final URLCoder PORT
PATH
public static final URLCoder PATH
PATH_SEGMENT
public static final URLCoder PATH_SEGMENT
QUERY
public static final URLCoder QUERY
QUERY_PARAM
public static final URLCoder QUERY_PARAM
FRAGMENT
public static final URLCoder FRAGMENT
URI
public static final URLCoder URI
HTTP_URL
public static final URLCoder HTTP_URL
values
public static URLCoder[] values()
- Returns an array containing the constants of this enum type, in
the order they are declared. This method may be used to iterate
over the constants as follows:
for (URLCoder c : URLCoder.values())
System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in
the order they are declared
valueOf
public static URLCoder valueOf(String name)
- Returns the enum constant of this type with the specified name.
The string must match exactly an identifier used to declare an
enum constant in this type. (Extraneous whitespace characters are
not permitted.)
- Parameters:
name - the name of the enum constant to be returned.
- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException - if this enum type has no constant
with the specified name
NullPointerException - if the argument is null
encode
public abstract String encode(String string,
String encoding)
throws UnsupportedEncodingException
- Throws:
UnsupportedEncodingException
encode
public final String encode(String string)
decode
public final String decode(String string)
decode
public final String decode(String string,
String encoding)
throws UnsupportedEncodingException
- Throws:
UnsupportedEncodingException
Copyright © 2013 Molindo GmbH. All Rights Reserved.