org.semanticdesktop.aperture.util
Class UrlUtil

java.lang.Object
  extended by org.semanticdesktop.aperture.util.UrlUtil

public class UrlUtil
extends Object

Offers utility methods related to URLs, network connections, etc.


Constructor Summary
UrlUtil()
           
 
Method Summary
static String normalizePath(String path)
          Remove relative references and "mistakes" like double slashes from the path.
static String normalizeQuery(String query)
          Normalizes a query string by sorting the query parameters alpabetically.
static URL normalizeURL(URL url)
          Normalizes a URL.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UrlUtil

public UrlUtil()
Method Detail

normalizeURL

public static URL normalizeURL(URL url)
Normalizes a URL. The following steps are taken to normalize a URL:


normalizePath

public static String normalizePath(String path)
Remove relative references and "mistakes" like double slashes from the path.

Parameters:
path - The path to normalize.
Returns:
The normalized path.

normalizeQuery

public static String normalizeQuery(String query)
Normalizes a query string by sorting the query parameters alpabetically.

Parameters:
query - The query string to normalize.
Returns:
The normalized query string.


Copyright © 2010 Aperture Development Team. All Rights Reserved.