Liqp (liquid template engine for java) accessing field of object

Viewed 1192

I'm trying to use Liqp to parse a string template but I am unable to access the fields of the objects that I put in the context....

Map<String, Object> model = new HashMap<>();
model.put("test", new Test("Value of field"));
Template template = Template.parse("Something {{test.field}}");
String output = template.render(model);

The field is public, has getters and every possible way of enabling access.

The ouptut of the above code is: "Something "

1 Answers
Related