cppyabm  1.0.17
An agent-based library to integrate C++ and Python
Public Member Functions | List of all members
unpacking_collector< policy > Class Template Reference

Helper class which collects positional, keyword, * and ** arguments for a Python function call. More...

#include <cast.h>

Public Member Functions

template<typename... Ts>
 unpacking_collector (Ts &&...values)
 
const tupleargs () const &
 
const dictkwargs () const &
 
tuple args () &&
 
dict kwargs () &&
 
object call (PyObject *ptr) const
 Call a Python function and pass the collected arguments. More...
 

Detailed Description

template<return_value_policy policy>
class unpacking_collector< policy >

Helper class which collects positional, keyword, * and ** arguments for a Python function call.

Definition at line 2102 of file cast.h.

Constructor & Destructor Documentation

◆ unpacking_collector()

template<return_value_policy policy>
template<typename... Ts>
unpacking_collector< policy >::unpacking_collector ( Ts &&...  values)
inlineexplicit

Definition at line 2105 of file cast.h.

Member Function Documentation

◆ args() [1/2]

template<return_value_policy policy>
tuple unpacking_collector< policy >::args ( ) &&
inline

Definition at line 2118 of file cast.h.

◆ args() [2/2]

template<return_value_policy policy>
const tuple& unpacking_collector< policy >::args ( ) const &
inline

Definition at line 2115 of file cast.h.

◆ call()

template<return_value_policy policy>
object unpacking_collector< policy >::call ( PyObject *  ptr) const
inline

Call a Python function and pass the collected arguments.

Definition at line 2122 of file cast.h.

◆ kwargs() [1/2]

template<return_value_policy policy>
dict unpacking_collector< policy >::kwargs ( ) &&
inline

Definition at line 2119 of file cast.h.

◆ kwargs() [2/2]

template<return_value_policy policy>
const dict& unpacking_collector< policy >::kwargs ( ) const &
inline

Definition at line 2116 of file cast.h.


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