Public Member Functions | Private Attributes | List of all members
simple_collector< policy > Class Template Reference

#include <cast.h>

Public Member Functions

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

Private Attributes

tuple m_args
 

Detailed Description

template<return_value_policy policy>
class simple_collector< policy >

Helper class which collects only positional arguments for a Python function call. A fancier version below can collect any argument, but this one is optimal for simple calls.

Definition at line 1633 of file cast.h.

Constructor & Destructor Documentation

◆ simple_collector()

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

Definition at line 1636 of file cast.h.

Member Function Documentation

◆ args() [1/2]

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

Definition at line 1642 of file cast.h.

◆ args() [2/2]

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

Definition at line 1639 of file cast.h.

◆ call()

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

Call a Python function and pass the collected arguments.

Definition at line 1645 of file cast.h.

◆ kwargs()

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

Definition at line 1640 of file cast.h.

Member Data Documentation

◆ m_args

template<return_value_policy policy>
tuple simple_collector< policy >::m_args
private

Definition at line 1654 of file cast.h.


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


gtsam
Author(s):
autogenerated on Sat Nov 16 2024 04:10:07