<commit_before>#ifndef ARABICA_XPATH_FUNCTION_RESOLVER_HPP
#define ARABICA_XPATH_FUNCTION_RESOLVER_HPP

namespace Arabica
{
namespace XPath
{

template<class string_type, class string_adaptor> class XPathFunction;
template<class string_type, class string_adaptor> class XPathExpression;

class UndefinedFunctionException : public std::runtime_error
{
public:
  UndefinedFunctionException(const std::string& thing) : std::runtime_error("The function '" + thing + "' is undefined.") { }
}; // class UndefinedFunctionException

template<class string_type, class string_adaptor = Arabica::default_string_adaptor<string_type> >
class FunctionResolver
{
public:
  virtual ~FunctionResolver() { }

  // TODO: should make this a QName
  virtual XPathFunction<string_type, string_adaptor>* 
      resolveFunction(const string_type& namespace_uri,
                      const string_type& name,
                      const std::vector<XPathExpression<string_type, string_adaptor> >& argExprs) const = 0; 
}; // class FunctionResolver

template<class string_type, class string_adaptor><commit_msg>removed TODO comment, because I actually did it sometime ago<commit_after>#ifndef ARABICA_XPATH_FUNCTION_RESOLVER_HPP
#define ARABICA_XPATH_FUNCTION_RESOLVER_HPP

namespace Arabica
{
namespace XPath
{

template<class string_type, class string_adaptor> class XPathFunction;
template<class string_type, class string_adaptor> class XPathExpression;

class UndefinedFunctionException : public std::runtime_error
{
public:
  UndefinedFunctionException(const std::string& thing) : std::runtime_error("The function '" + thing + "' is undefined.") { }
}; // class UndefinedFunctionException

template<class string_type, class string_adaptor = Arabica::default_string_adaptor<string_type> >
class FunctionResolver
{
public:
  virtual ~FunctionResolver() { }

  virtual XPathFunction<string_type, string_adaptor>* 
      resolveFunction(const string_type& namespace_uri,
                      const string_type& name,
                      const std::vector<XPathExpression<string_type, string_adaptor> >& argExprs) const = 0; 
}; // class FunctionResolver

template<class string_type, class string_adaptor>
{'fraction_non_alphanumeric': 0.081539166284929, 'fraction_numerical': 0.0009161704076958314, 'mean_word_length': 5.558558558558558, 'pattern_counts': {'":': 0, '<': 19, '<?xml version=': 0, '>': 19, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6072681', 'n_tokens_mistral': 639, 'n_tokens_neox': 607, 'n_words': 146}