com.xmlserv.util
Class Coder

java.lang.Object
  |
  +--com.xmlserv.util.Coder

public class Coder
extends java.lang.Object

This class encodes/decodes stuff to/from the web.


Method Summary
static void main(java.lang.String[] args)
           
static java.lang.String URLDecode(java.lang.String enc)
          URLDecode a string.
static java.lang.String URLEncode(java.lang.String str)
          URLEncode a string.
static java.lang.String uudecode(java.lang.String base64string)
          uudecode(base64) the given string. useful for decoding basic Authentication
static java.lang.String uuencode(java.lang.String str)
          uuencode(base64) the given String. useful for encoding basic authentication.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

uudecode

public static java.lang.String uudecode(java.lang.String base64string)
uudecode(base64) the given string. useful for decoding basic Authentication
Parameters:
str - the String to decode.
Returns:
the decoded string.

uuencode

public static java.lang.String uuencode(java.lang.String str)
uuencode(base64) the given String. useful for encoding basic authentication.
Parameters:
str - the String to encode.
Returns:
the encoded string.

URLDecode

public static java.lang.String URLDecode(java.lang.String enc)
URLDecode a string. This is useful when your handling CGI-arguments..
Parameters:
enc - the encoded String.
Returns:
an unescaped String. ('%dd' => 'c', '+' => ' ')

URLEncode

public static java.lang.String URLEncode(java.lang.String str)
URLEncode a string. Only a convenience function for java.net.URLEncoder.encode ()
Parameters:
str - the String to URLEncode.

main

public static void main(java.lang.String[] args)