public class UrlVar extends SimpleVar
The format for this var is
The advantage of using this variable is that you can resolve URLs with special protocols such as
See UriResolver for the kinds of URIs that can be resolved.
Uses the URI resolver returned by RestRequest.getUriResolver().
| Modifier and Type | Field and Description |
|---|---|
static String |
NAME
The name of this variable.
|
| Constructor and Description |
|---|
UrlVar()
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
canResolve(VarResolverSession session)
Returns
|
String |
resolve(VarResolverSession session,
String key)
The interface that needs to be implemented for subclasses of
SimpleVar. |
allowNested, allowRecurse, doResolve, getNamepublic static final String NAME
public UrlVar()
public String resolve(VarResolverSession session, String key)
VarSimpleVar.public boolean canResolve(VarResolverSession session)
VarFor example, some variable cannot resolve unless specific context or session objects are available.
canResolve in class Varsession - The current session.Copyright © 2016–2019 The Apache Software Foundation. All rights reserved.