Skip to main content

VarResolver

The Microservice API incorporates the Simple Variable Language API. The variable resolver can be augmented through the following methods:

Microservice.Buildervars(Class...)varBean(Class,Object)

A typical usage pattern is shown below:

// $A used in variable resolver.
VarResolver varResolver = Microservice.getInstance().getVarResolver();
System.out.println(varResolver.resolve("Main class is set to $MF{Main-Class, unknown}"));

The variable resolver becomes much more powerful when used in REST resource annotations which will be described latter in juneau-microservice-jetty By default, support for the following variables are provided: