Package org.xwiki.url

Interface URLNormalizer<T>

  • Type Parameters:
    T - the type of object to return (eg ExtendedURL, URL)

    public interface URLNormalizer<T>
    Normalize a relative URL. Various implementations can exist, for example one implementation may normalize the passed relative URL into a full absolute URL object. Another implementation may simply prefix the passed relative URL with a Servlet Container's webapp name (aka application context name). Note that in general the implementations will depends on the Container in which XWiki is executing (eg Servlet Container).

    It's also important that Normalizers should be independent of URL Scheme formats since they should be usable for all URL Schemes. Note that Normalizers should not replace ResourceReferenceSerializer implementations.

    $Id: 0f660ffe97a994533d2090b556d18672ad6cf2a2 $
    • Method Detail

      • normalize

        T normalize​(ExtendedURL partialURL)
        partialURL - the partial URL to normalize
        the normalized URL, what is done depends on the implementation