|
SAP NetWeaver 7.40 SP 06 KMC | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sap.netweaver.bc.rf.common.UriCodec
public class UriCodec
Utility class for decoding/encoding URIs in HTTP requests. Handles escaping of reserved as well as non-7bit characters.
Instances of this class are not threadsafe. The class methods are threadsafe, however.
Copyright (c) SAP AG 2001-2003
| Constructor Summary | |
|---|---|
UriCodec()
Creates a new URICoded Instance. |
|
| Method Summary | |
|---|---|
String |
decode(String quoted)
Converts an encoded URI into a Java String. |
static String |
Decode(String quotedURI)
Decode the given URI. |
static Properties |
DecodeQuery(String query)
Decode the given http query string. |
String |
encode(String unquoted)
Converts a URI in plain Java String to a format suitable for transmitting in Http requests. |
static String |
Encode(String unquotedURI)
Encode the given URI. |
String |
encodePath(String unquoted)
Converts a URI in plain Java String to a format suitable for transmitting in Http requests. |
static String |
EncodePath(String path)
Encode the given http path string. |
static String |
EncodeQuery(Properties params)
Encode the given http query string. |
static String |
getURIEncoding(byte b)
Get string with URI escapes for given byte. |
static int |
getUTF8SequenceLength(byte b)
Return the sequence length of a UTF-8 sequence starting with the given byte. |
static boolean |
looksLikeUTF8(byte[] bytes)
Determines if bytes are a valid UTF-8 sequence. |
static String |
RemoveParameter(String query,
String paramName)
Remove a parameter from a query string if present. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public UriCodec()
| Method Detail |
|---|
public static String Encode(String unquotedURI)
unquotedURI - non-encoded URI
public static String Decode(String quotedURI)
quotedURI - encoded URI
public static String EncodeQuery(Properties params)
params - parameter to encode
public static String EncodePath(String path)
path - TBD: Description of the incoming method parameter
public static Properties DecodeQuery(String query)
query - http uri encoded
public static String RemoveParameter(String query,
String paramName)
query - to remove parameter fromparamName - name of parameter
public String decode(String quoted)
This method is not multithread-safe.
quoted - the quoted URI
public String encode(String unquoted)
This method is not multithread-safe.
unquoted - URI in unquoted form
public String encodePath(String unquoted)
This method is not multithread-safe.
unquoted - URI in unquoted form
public static final boolean looksLikeUTF8(byte[] bytes)
bytes - TBD: Description of the incoming method parameter
public static final int getUTF8SequenceLength(byte b)
b - byte for sequence start
public static final String getURIEncoding(byte b)
b - byte to escape
| Access Rights |
|---|
| SC | DC | Public Part | ACH |
|---|---|---|---|
[sap.com] KMC-CM
|
[sap.com] tc/km/frwk
|
api
|
EP-KM-CM
|
[sap.com] KMC-WPC
|
[sap.com] tc/kmc/wpc/wpcfacade
|
api
|
EP-PIN-WPC-WCM
|
|
SAP NetWeaver 7.40 SP 06 KMC | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||