14 # pragma warning(disable:4231)
17 # pragma warning(disable:4251)
20 # pragma warning(disable:4275)
23 # pragma warning(disable:4800)
27 #include <boost/python.hpp>
33 using namespace boost::python;
41 class_ < FunctionFactory, bases<>,
44 "The factory for creating derived classes of FunctionBase.",
47 .def (
"instance", &FunctionFactory::instance,
48 return_value_policy < reference_existing_object > (),
49 "instance () -> FunctionFactory\n"
51 "Returns the single instance of the FunctionFactory." )
53 .staticmethod(
"instance" )
55 .def (
"names", &FunctionFactory::names,
56 return_value_policy < copy_const_reference > (),
57 "names () -> sequence\n"
59 "Returns the names of the available FunctinBase derived classes." )
61 .def (
"create", &FunctionFactory::create,
62 return_value_policy < reference_existing_object > (),
63 "create ( string ) -> FunctionBase\n"
65 "Returns the newly created object derived from FunctionBase." )
67 .def (
"add", &FunctionFactory::add,
68 with_custodian_and_ward_postcall < 1, 2 > (),
69 "add ( FunctionBase ) -> None\n"
71 "Adds the function to the factory." )