Function importPyListToVectorString(PyObject *, vector<string>&, const string&)

Function Documentation

bool importPyListToVectorString(PyObject *list_input, vector<string> &output, const string &err_msg)

Imports the provided input list to the output vector. Sets the Python error message and returns false if one of the list elements is not a string type.

Return
true if no error is thrown, false otherwise
Parameters
  • list_input: a Python list object to iterate over
  • output: the output vector of strings to push to
  • err_msg: error message to through if an element is not of float type