* Whether this page requires a login
*/
public SoneTemplatePage(String path, Template template, String pageTitleKey, WebInterface webInterface, boolean requireLogin) {
- super(path, template, webInterface.l10n(), pageTitleKey, "noPermission.html");
+ super(path, template, webInterface.getL10n(), pageTitleKey, "noPermission.html");
this.webInterface = webInterface;
this.requireLogin = requireLogin;
template.set("webInterface", webInterface);
*
* @return The node’s l10n helper
*/
- public BaseL10n l10n() {
+ public BaseL10n getL10n() {
return sonePlugin.l10n().getBase();
}
templateFactory.addAccessor(Reply.class, new ReplyAccessor(core()));
templateFactory.addAccessor(Identity.class, new IdentityAccessor(core()));
templateFactory.addFilter("date", new DateFilter());
- templateFactory.addFilter("l10n", new L10nFilter(l10n()));
+ templateFactory.addFilter("l10n", new L10nFilter(getL10n()));
templateFactory.addFilter("substring", new SubstringFilter());
templateFactory.addFilter("xml", new XmlFilter());
templateFactory.addFilter("change", new RequestChangeFilter());
@Override
protected JsonObject createJsonObject(Request request) {
String key = request.getHttpRequest().getParam("key");
- String translation = webInterface.l10n().getString(key);
+ String translation = webInterface.getL10n().getString(key);
return new JsonObject().put("value", translation);
}