Package io.vertx.mutiny.uritemplate
Class Variables
java.lang.Object
io.vertx.mutiny.uritemplate.Variables
- All Implemented Interfaces:
MutinyDelegate
Holds a set of name/value pairs where each value can be a
String or a List<String> or a Map<String, String>.
NOTE: This class has been automatically generated from the original non Mutiny-ified interface.
- See Also:
-
Variables
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddAll(io.vertx.core.json.JsonObject json) Populates with a JSON object:nullare conservedJsonArrayis converted toList<String>JsonObjectis converted toMap<String, String>any other value is converted to a string Note that nested JSON elements are converted to a string, so { "user": { "first_name": "John", "last_name": "Doe", "address" : { "city": "Paris", etc... } } } flattens the JSON "address" to the string "{\"city\":\"Paris\",etc...}".clear()booleanio.vertx.uritemplate.VariablesGet the delegate instance.inthashCode()names()static VariablesnewInstance(io.vertx.uritemplate.Variables delegate) Creates a new instance of theVariables.Set a single variable.Set a list variable.Set a map variable.setAll(io.vertx.core.json.JsonObject json) LikeaddAll(JsonObject)but overwrites previous variables.toString()static Variablesstatic Variablesvariables(io.vertx.core.json.JsonObject json) Create an instance populated from a JSON object:nullare conservedJsonArrayis converted toList<String>JsonObjectis converted toMap<String, String>any other value is converted to a string Note that nested JSON elements are converted to a string, so { "user": { "first_name": "John", "last_name": "Doe", "address" : { "city": "Paris", etc... } } } flattens the JSON "address" to the string "{\"city\":\"Paris\",etc...}".
-
Field Details
-
__TYPE_ARG
-
-
Constructor Details
-
Variables
public Variables(io.vertx.uritemplate.Variables delegate) Create a new instance ofVariablesdelegating to the given (non-null) instance ofVariables. -
Variables
-
-
Method Details
-
getDelegate
public io.vertx.uritemplate.Variables getDelegate()Get the delegate instance.This method returns the instance on which this shim is delegating the calls. And so, give you access to the bare API.
- Specified by:
getDelegatein interfaceMutinyDelegate- Returns:
- the delegate instance
-
variables
- Returns:
- an empty instance
-
variables
Create an instance populated from a JSON object:nullare conservedJsonArrayis converted toList<String>JsonObjectis converted toMap<String, String>- any other value is converted to a string
- Parameters:
json- the json that populates the returned variables- Returns:
- an instance populated from a JSON object
-
set
Set a single variable.- Parameters:
name- the variable namevalue- the variable value- Returns:
- a reference to this, so the API can be used fluently
-
set
Set a list variable.- Parameters:
name- the variable namevalue- the variable value- Returns:
- a reference to this, so the API can be used fluently
-
set
Set a map variable.- Parameters:
name- the variable namevalue- the variable value- Returns:
- a reference to this, so the API can be used fluently
-
setAll
LikeaddAll(JsonObject)but overwrites previous variables. -
addAll
Populates with a JSON object:nullare conservedJsonArrayis converted toList<String>JsonObjectis converted toMap<String, String>- any other value is converted to a string
- Parameters:
json- the json that populates the returned variables- Returns:
- a reference to this, so the API can be used fluently
-
clear
-
names
- Returns:
- the set of variable names
-
get
- Returns:
- the value of the variable
name
-
getSingle
- Returns:
- the single value of the variable
name
-
getList
- Returns:
- the list value of the variable
name
-
getMap
- Returns:
- the map value of the variable
name
-
newInstance
Creates a new instance of theVariables. -
hashCode
public int hashCode() -
equals
-
toString
-