class XSLTTemplatesContextResolver implements ContextResolver<XSLTTemplatesContextResolver> {

    public void addTemplates(String name, Templates templates) {
        if (templatesMap.putIfAbsent(name, templates) != null) {
            throw new IllegalArgumentException(String.format("Template with name '%s' already registered", name));
        }
    }

    public  XSLTTemplatesContextResolver(TemplatesParser templatesParser);

}