CPP-AP 2.2.6
Command-line argument parser for C++20
Loading...
Searching...
No Matches
ap::action::detail::apply_visitor< T > Struct Template Reference

A visitor structure used to apply value actions. More...

#include <utility.hpp>

Public Types

using value_type = T
 

Public Member Functions

void operator() (const callable_type< action_type::observe, value_type > &action) const
 The call operator overload for the observe action type.
 
void operator() (const callable_type< action_type::transform, value_type > &action) const
 The call operator overload for the transform action type.
 
void operator() (const callable_type< action_type::modify, value_type > &action) const
 The call operator overload for the modify action type.
 

Public Attributes

value_type & value
 A reference to the argument's value for which the action will be applied.
 

Detailed Description

template<ap::detail::c_argument_value_type T>
struct ap::action::detail::apply_visitor< T >

A visitor structure used to apply value actions.

Template Parameters
TThe argument's value type

Definition at line 50 of file utility.hpp.

Member Typedef Documentation

◆ value_type

Definition at line 51 of file utility.hpp.

Member Function Documentation

◆ operator()() [1/3]

void ap::action::detail::apply_visitor< T >::operator() ( const callable_type< action_type::modify, value_type > &  action) const
inline

The call operator overload for the modify action type.

Parameters
actionThe modify action callable.

Definition at line 73 of file utility.hpp.

◆ operator()() [2/3]

void ap::action::detail::apply_visitor< T >::operator() ( const callable_type< action_type::observe, value_type > &  action) const
inline

The call operator overload for the observe action type.

Parameters
actionThe observe action callable.

Definition at line 57 of file utility.hpp.

◆ operator()() [3/3]

void ap::action::detail::apply_visitor< T >::operator() ( const callable_type< action_type::transform, value_type > &  action) const
inline

The call operator overload for the transform action type.

Parameters
actionThe transform action callable.

Definition at line 65 of file utility.hpp.

Member Data Documentation

◆ value

A reference to the argument's value for which the action will be applied.

Definition at line 77 of file utility.hpp.


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