public class Encode extends Object
Constructor and Description |
---|
Encode() |
Modifier and Type | Method and Description |
---|---|
static MultivaluedHashMap<String,String> |
decode(MultivaluedHashMap<String,String> map)
decode an encoded map
|
static MultivaluedHashMap<String,String> |
decode(MultivaluedHashMap<String,String> map,
String charset)
decode an encoded map
|
static String |
decode(String string) |
static String |
decodePath(String path) |
static MultivaluedHashMap<String,String> |
encode(MultivaluedHashMap<String,String> map) |
static String |
encodeFragment(String value)
Keep encoded values "%..." and template parameters intact.
|
static String |
encodeFragmentAsIs(String nameOrValue) |
protected static String |
encodeFromArray(String segment,
String[] encodingMap,
boolean encodePercent) |
static String |
encodeMatrixParam(String value)
Keep encoded values "%..." and template parameters intact.
|
static String |
encodeNonCodes(String string)
Encode '%' if it is not an encoding sequence
|
static String |
encodePath(String value)
Keep encoded values "%...", matrix parameters, template parameters, and '/' characters intact.
|
static String |
encodePathAsIs(String segment)
Encode via RFC 3986.
|
static String |
encodePathSaveEncodings(String segment)
Keep any valid encodings from string i.e.
|
static String |
encodePathSegment(String value)
Keep encoded values "%...", matrix parameters and template parameters intact.
|
static String |
encodePathSegmentAsIs(String segment)
Encode via RFC 3986.
|
static String |
encodePathSegmentSaveEncodings(String segment)
Keep any valid encodings from string i.e.
|
static String |
encodeQueryParam(String value)
Keep encoded values "%..." and template parameters intact.
|
static String |
encodeQueryParamAsIs(String nameOrValue)
Encodes everything of a query parameter name or value.
|
static String |
encodeQueryParamSaveEncodings(String segment)
Keep any valid encodings from string i.e.
|
static String |
encodeQueryString(String value)
Keep encoded values "%..." and template parameters intact.
|
static String |
encodeValue(String segment,
String[] encoding)
Keep encoded values "%..." and template parameters intact i.e.
|
static String |
pathParamReplacement(String segment,
List<String> params) |
static boolean |
savePathParams(String segment,
StringBuilder newSegment,
List<String> params) |
public static String encodeQueryString(String value)
public static String encodePath(String value)
public static String encodePathSegment(String value)
public static String encodeFragment(String value)
public static String encodeMatrixParam(String value)
public static String encodeQueryParam(String value)
public static String encodeNonCodes(String string)
string
- public static boolean savePathParams(String segment, StringBuilder newSegment, List<String> params)
public static String encodeValue(String segment, String[] encoding)
segment
- encoding
- public static String encodePathAsIs(String segment)
public static String encodePathSaveEncodings(String segment)
segment
- public static String encodePathSegmentAsIs(String segment)
public static String encodePathSegmentSaveEncodings(String segment)
segment
- public static String encodeQueryParamAsIs(String nameOrValue)
nameOrValue
- public static String encodeQueryParamSaveEncodings(String segment)
segment
- protected static String encodeFromArray(String segment, String[] encodingMap, boolean encodePercent)
public static MultivaluedHashMap<String,String> decode(MultivaluedHashMap<String,String> map)
map
- public static MultivaluedHashMap<String,String> decode(MultivaluedHashMap<String,String> map, String charset)
map
- charset
- public static MultivaluedHashMap<String,String> encode(MultivaluedHashMap<String,String> map)
Copyright © 2019 JBoss by Red Hat. All rights reserved.