public interface UriTemplate
A template is immutable and thread safe, it can be safely shared between threads after its creation.
If you are sharing a template as a static variables, keep in mind that of(String)
can fail and create
a classloading issue.
Modifier and Type | Method and Description |
---|---|
String |
expandToString(Variables variables)
Expand this template to a string.
|
String |
expandToString(Variables variables,
ExpandOptions options)
Expand this template to a string.
|
static UriTemplate |
of(String uri)
Create a template from a string
uri . |
static UriTemplate of(String uri)
uri
.
The string uri
is validated and parsed, invalid inputs are rejected with a IllegalArgumentException
.
uri
- the template stringIllegalArgumentException
- when the templateString expandToString(Variables variables)
variables
- the variablesvariables
String expandToString(Variables variables, ExpandOptions options)
variables
- the variablesoptions
- the options to control template expansionvariables
Copyright © 2023 Eclipse. All rights reserved.