strusAnalyzer  0.17
Classes | Public Types | Public Member Functions | List of all members
strus::analyzer::FunctionView Class Reference

Structure describing the internal representation of a normalizer/tokenizer/aggregator function in the analyzer. More...

#include <functionView.hpp>

Classes

struct  is_atomic
 Conditional for atomic type. More...
 

Public Types

typedef std::pair< std::string,
std::string > 
NamedParameter
 

Public Member Functions

 FunctionView ()
 Default constructor. More...
 
 FunctionView (const FunctionView &o)
 Copy constructor. More...
 
 FunctionView (const std::string &name_, const std::vector< NamedParameter > &params_)
 Constructor. More...
 
 FunctionView (const std::string &name_)
 Constructor. More...
 
template<typename value_type >
strus::enable_if< is_atomic
< value_type >::value,
FunctionView & >::type 
operator() (const char *name_, const value_type &value_)
 Operator to build parameter list (for atomic value type) More...
 
template<typename value_type >
strus::enable_if< is_atomic
< value_type >::value,
FunctionView & >::type 
operator() (const char *name_, const std::map< std::string, value_type > &value_)
 Operator to build parameter list (for map of string to atomic value type) More...
 
template<typename value_type >
strus::enable_if< is_atomic
< value_type >::value,
FunctionView & >::type 
operator() (const char *name_, const std::vector< value_type > &value_)
 Operator to build parameter list (for map of string to atomic value type) More...
 
template<typename value_type >
strus::enable_if
< strus::is_same
< NumericVariant, value_type >
::value, FunctionView & >
::type 
operator() (const char *name_, const value_type &value_)
 Operator to build parameter list (for value type numeric variant) More...
 
const std::string & name () const
 Get the name of the function. More...
 
const std::vector
< NamedParameter > & 
parameter () const
 Get the internal representation of the named parameters of the function. More...
 

Detailed Description

Structure describing the internal representation of a normalizer/tokenizer/aggregator function in the analyzer.

Note
The internal representation may not be suitable for reconstructing the object

Member Typedef Documentation

typedef std::pair<std::string,std::string> strus::analyzer::FunctionView::NamedParameter

Constructor & Destructor Documentation

strus::analyzer::FunctionView::FunctionView ( )
inline

Default constructor.

strus::analyzer::FunctionView::FunctionView ( const FunctionView o)
inline

Copy constructor.

strus::analyzer::FunctionView::FunctionView ( const std::string &  name_,
const std::vector< NamedParameter > &  params_ 
)
inline

Constructor.

Parameters
[in]name_name of the function
[in]params_list of named parameters
strus::analyzer::FunctionView::FunctionView ( const std::string &  name_)
inlineexplicit

Constructor.

Parameters
[in]name_name of the function
[in]params_list of named parameters

Member Function Documentation

const std::string& strus::analyzer::FunctionView::name ( ) const
inline

Get the name of the function.

Returns
name of the function
template<typename value_type >
strus::enable_if<is_atomic<value_type>::value,FunctionView&>::type strus::analyzer::FunctionView::operator() ( const char *  name_,
const value_type &  value_ 
)
inline

Operator to build parameter list (for atomic value type)

Parameters
[in]name_name of the parameter
[in]value_value of the parameter
template<typename value_type >
strus::enable_if<is_atomic<value_type>::value,FunctionView&>::type strus::analyzer::FunctionView::operator() ( const char *  name_,
const std::map< std::string, value_type > &  value_ 
)
inline

Operator to build parameter list (for map of string to atomic value type)

Parameters
[in]name_name of the parameter
[in]value_value of the parameter
template<typename value_type >
strus::enable_if<is_atomic<value_type>::value,FunctionView&>::type strus::analyzer::FunctionView::operator() ( const char *  name_,
const std::vector< value_type > &  value_ 
)
inline

Operator to build parameter list (for map of string to atomic value type)

Parameters
[in]name_name of the parameter
[in]value_value of the parameter
template<typename value_type >
strus::enable_if<strus::is_same<NumericVariant,value_type>::value,FunctionView&>::type strus::analyzer::FunctionView::operator() ( const char *  name_,
const value_type &  value_ 
)
inline

Operator to build parameter list (for value type numeric variant)

Parameters
[in]name_name of the parameter
[in]value_value of the parameter
const std::vector<NamedParameter>& strus::analyzer::FunctionView::parameter ( ) const
inline

Get the internal representation of the named parameters of the function.

Note
The parameter list is not the list of parameters passed on the construction of the object but a view to the internal representation of the parameters of the function
Returns
elements of the function

The documentation for this class was generated from the following file: