public abstract class XWikiDefaultURLFactory extends Object implements XWikiURLFactory
Constructor and Description |
---|
XWikiDefaultURLFactory() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createAttachmentRevisionURL, createAttachmentURL, createExternalURL, createResourceURL, createSkinURL, createSkinURL, createURL, createURL, getServerURL, init
public URL createURL(String spaces, String name, XWikiContext context)
createURL
in interface XWikiURLFactory
spaces
- a serialized space reference which can contain one or several spaces (e.g. "space1.space2"). If
a space name contains a dot (".") it must be passed escaped as in "space1\.with\.dot.space2"public URL createExternalURL(String spaces, String name, String action, String querystring, String anchor, XWikiContext context)
createExternalURL
in interface XWikiURLFactory
spaces
- a serialized space reference which can contain one or several spaces (e.g. "space1.space2"). If
a space name contains a dot (".") it must be passed escaped as in "space1\.with\.dot.space2"querystring
- the URL-encoded Query String. It's important to realize that the implementation of this
method cannot encode it automatically since the Query String is passed as a String (and it's not possible
to differentiate between a '=' character that should be encoded and one that shouldn't. Imagine an input
of 'a=&b=c' which can be understood either as 'a' = '&b=c' or as 'a' = '' and 'b' = 'c'). Ideally
we would need an API signature that accepts a Map<String, String>
for the Query String, for
examplepublic URL createURL(String spaces, String name, String action, XWikiContext context)
createURL
in interface XWikiURLFactory
spaces
- a serialized space reference which can contain one or several spaces (e.g. "space1.space2"). If
a space name contains a dot (".") it must be passed escaped as in "space1\.with\.dot.space2"public URL createURL(String spaces, String name, String action, String querystring, String anchor, XWikiContext context)
createURL
in interface XWikiURLFactory
spaces
- a serialized space reference which can contain one or several spaces (e.g. "space1.space2"). If
a space name contains a dot (".") it must be passed escaped as in "space1\.with\.dot.space2"querystring
- the URL-encoded Query String. It's important to realize that the implementation of this
method cannot encode it automatically since the Query String is passed as a String (and it's not possible
to differentiate between a '=' character that should be encoded and one that shouldn't. Imagine an input
of 'a=&b=c' which can be understood either as 'a' = '&b=c' or as 'a' = '' and 'b' = 'c'). Ideally
we would need an API signature that accepts a Map<String, String>
for the Query String, for
examplepublic URL createSkinURL(String filename, String spaces, String name, XWikiContext context)
createSkinURL
in interface XWikiURLFactory
public URL createAttachmentURL(String filename, String spaces, String name, String action, String querystring, XWikiContext context)
createAttachmentURL
in interface XWikiURLFactory
spaces
- a serialized space reference which can contain one or several spaces (e.g. "space1.space2"). If
a space name contains a dot (".") it must be passed escaped as in "space1\.with\.dot.space2"querystring
- the URL-encoded Query String. It's important to realize that the implementation of this
method cannot encode it automatically since the Query String is passed as a String (and it's not possible
to differentiate between a '=' character that should be encoded and one that shouldn't. Imagine an input
of 'a=&b=c' which can be understood either as 'a' = '&b=c' or as 'a' = '' and 'b' = 'c'). Ideally
we would need an API signature that accepts a Map<String, String>
for the Query String, for
examplepublic URL createAttachmentRevisionURL(String filename, String spaces, String name, String revision, String querystring, XWikiContext context)
createAttachmentRevisionURL
in interface XWikiURLFactory
spaces
- a serialized space reference which can contain one or several spaces (e.g. "space1.space2"). If
a space name contains a dot (".") it must be passed escaped as in "space1\.with\.dot.space2"querystring
- the URL-encoded Query String. It's important to realize that the implementation of this
method cannot encode it automatically since the Query String is passed as a String (and it's not possible
to differentiate between a '=' character that should be encoded and one that shouldn't. Imagine an input
of 'a=&b=c' which can be understood either as 'a' = '&b=c' or as 'a' = '' and 'b' = 'c'). Ideally
we would need an API signature that accepts a Map<String, String>
for the Query String, for
examplepublic URL createAttachmentRevisionURL(String filename, String spaces, String name, String revision, XWikiContext context)
public URL getRequestURL(XWikiContext context)
getRequestURL
in interface XWikiURLFactory
public String getURL(URL url, XWikiContext context)
XWikiURLFactory
getURL
in interface XWikiURLFactory
url
- the URL to convertCopyright © 2004–2018 XWiki. All rights reserved.