HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TfPyKwArg Struct Reference

#include <pyInvoke.h>

Public Member Functions

template<typename T >
 TfPyKwArg (const std::string &nameIn, const T &valueIn)
 

Public Attributes

std::string name
 
TfPyObjWrapper value
 

Detailed Description

Wrapper object for a keyword-argument pair in a call to TfPyInvoke*. Any value type may be provided, as long as it is convertible to Python. Typically passed as an inline temporary object:

const bool ok = TfPyInvoke(
"MyModule", "MyFunction",
arg1value, arg2value, TfPyKwArg("arg4", arg4value));
1 def MyFunction(arg1, arg2, arg3 = None, arg4 = None, arg5 = None):
2  # ...

Definition at line 86 of file pyInvoke.h.

Constructor & Destructor Documentation

template<typename T >
TfPyKwArg::TfPyKwArg ( const std::string nameIn,
const T valueIn 
)
inline

Definition at line 89 of file pyInvoke.h.

Member Data Documentation

std::string TfPyKwArg::name

Definition at line 99 of file pyInvoke.h.

TfPyObjWrapper TfPyKwArg::value

Definition at line 100 of file pyInvoke.h.


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