Package org.restlet.engine.util
Class ReferenceUtils
- java.lang.Object
-
- org.restlet.engine.util.ReferenceUtils
-
public class ReferenceUtils extends java.lang.Object
Utilities related to URI references.- Author:
- Jerome Louvel
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.String
format(org.restlet.data.Reference resourceRef, boolean isProxied, org.restlet.Request request)
Returns the request URI.static org.restlet.data.Reference
getOriginalRef(org.restlet.data.Reference resourceRef, org.restlet.util.Series<org.restlet.data.Header> headers)
Returns the original reference especially by detecting potential proxy forwardings.static org.restlet.data.Reference
update(org.restlet.data.Reference resourceRef, org.restlet.Request request)
Returns the request URI.
-
-
-
Method Detail
-
update
public static org.restlet.data.Reference update(org.restlet.data.Reference resourceRef, org.restlet.Request request)
Returns the request URI.- Parameters:
resourceRef
- The resource reference.request
- The parent request.- Returns:
- The absolute request URI.
-
format
public static java.lang.String format(org.restlet.data.Reference resourceRef, boolean isProxied, org.restlet.Request request)
Returns the request URI.- Parameters:
resourceRef
- The resource reference.isProxied
- Indicates if the request goes through a proxy and requires an absolute URI.request
- The parent request.- Returns:
- The absolute request URI.
-
getOriginalRef
public static org.restlet.data.Reference getOriginalRef(org.restlet.data.Reference resourceRef, org.restlet.util.Series<org.restlet.data.Header> headers)
Returns the original reference especially by detecting potential proxy forwardings.- Parameters:
resourceRef
- The request's resource reference.headers
- The set of request's headers.- Returns:
- The original reference.
-
-