Lumiera  0.pre.03
»edit your freedom«
VerbHolder< REC, RET(ARGS...)> Struct Template Reference

#include "lib/verb-visitor.hpp"

Description

template<class REC, class RET, typename... ARGS>
struct lib::VerbHolder< REC, RET(ARGS...)>

Building block: actual storage for a "verb" (function pointer), together with the pre-bound invocation arguments for this specific operation.

Definition at line 137 of file verb-visitor.hpp.

Public Types

using Args = std::tuple< ARGS... >
 
using SequenceIterator = typename meta::BuildIdxIter< ARGS... >::Ascending
 meta-sequence to pick argument values from the storage tuple
 
using Verb = VerbToken< REC, RET(ARGS...)>
 
- Public Types inherited from VerbToken< REC, RET(ARGS...)>
typedef RET(REC::* Handler) (ARGS...)
 

Public Member Functions

template<typename... PARS>
 VerbHolder (typename Verb::Handler handlerRef, Literal verbID, PARS &&... args)
 
RET applyTo (REC &receiver) override
 
Literal getID () const override
 
- Public Member Functions inherited from VerbInvoker< REC, RET >
bool operator!= (VerbInvoker const &o) const
 
bool operator== (VerbInvoker const &o) const
 
- Public Member Functions inherited from CloneValueSupport< polyvalue::EmptyBase >
virtual void cloneInto (void *targetBuffer) const=0
 
- Public Member Functions inherited from VerbToken< REC, RET(ARGS...)>
 VerbToken (Handler handlerFunction, Literal token)
 
RET applyTo (REC &receiver, ARGS &&...args)
 
Literal const & getID () const
 
 operator string () const
 
bool operator!= (VerbToken const &o) const
 
bool operator== (VerbToken const &o) const
 equality of VerbToken, based on equality of the #token_ Literal More...
 

Public Attributes

Args args_
 Storage for the argument tuple.
 

Private Member Functions

template<size_t... idx>
RET invokeVerb (REC &receiver, meta::IndexSeq< idx... >)
 

Additional Inherited Members

- Protected Attributes inherited from VerbToken< REC, RET(ARGS...)>
Handler handler_
 
Literal token_
 

Member Function Documentation

◆ invokeVerb()

RET invokeVerb ( REC &  receiver,
meta::IndexSeq< idx... >   
)
inlineprivate

actual function invocation, thereby unpacking the argument tuple

Definition at line 172 of file verb-visitor.hpp.

+ Inheritance diagram for VerbHolder< REC, RET(ARGS...)>:
+ Collaboration diagram for VerbHolder< REC, RET(ARGS...)>:

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