Steppable 0.0.1
A CAS project written from scratch in C++
Loading...
Searching...
No Matches
steppable::__internals::parameter Namespace Reference

Contains the parameter utilities to allow named parameters to be passed into functions. More...

Classes

struct  Parameter
 Stores the name of a parameter. More...
struct  ParameterMap
 An object containing all parameters and their values passed into a function. More...
struct  ValuedParameter
 A parameter with a name and value. More...

Typedefs

using ValueMap = std::vector<ValuedParameter>
 A type containing all the parameters of a function, in calling order.

Functions

Parameter operator""_p (const char *name, size_t)
 Convert a literal to a parameter, using a shorthand notation.
template<typename... Params>
ParameterMap processParams (Params... params)
 Process parameters passed into a function.

Detailed Description

Contains the parameter utilities to allow named parameters to be passed into functions.

Typedef Documentation

◆ ValueMap

A type containing all the parameters of a function, in calling order.

Function Documentation

◆ operator""_p()

Parameter steppable::__internals::parameter::operator""_p ( const char * name,
size_t  )
inline

Convert a literal to a parameter, using a shorthand notation.

Parameters
nameThe name of the parameter, expressed as a simple string literal.
Returns
A Parameter object to set the value of the parameter.

◆ processParams()

template<typename... Params>
ParameterMap steppable::__internals::parameter::processParams ( Params... params)

Process parameters passed into a function.

Takes in all arguments from a variadic function, and processes them as parameters.

Parameters
paramsThe parameters passed into a function.
Returns
An instance of ParameterMap containing a list of the parameters.
Here is the caller graph for this function:
Untitled