Update contrib.
1 // Copyright David Abrahams 2001.
2 // Distributed under the Boost Software License, Version 1.0. (See
3 // accompanying file LICENSE_1_0.txt or copy at
4 // http://www.boost.org/LICENSE_1_0.txt)
5 #ifndef REGISTRY_DWA20011127_HPP
6 # define REGISTRY_DWA20011127_HPP
7 # include <boost/python/type_id.hpp>
8 # include <boost/python/converter/to_python_function_type.hpp>
9 # include <boost/python/converter/rvalue_from_python_data.hpp>
10 # include <boost/python/converter/constructor_function.hpp>
11 # include <boost/python/converter/convertible_function.hpp>
13 namespace boost { namespace python { namespace converter {
17 // This namespace acts as a sort of singleton
20 // Get the registration corresponding to the type, creating it if necessary
21 BOOST_PYTHON_DECL registration const& lookup(type_info);
23 // Get the registration corresponding to the type, creating it if
24 // necessary. Use this first when the type is a shared_ptr.
25 BOOST_PYTHON_DECL registration const& lookup_shared_ptr(type_info);
27 // Return a pointer to the corresponding registration, if one exists
28 BOOST_PYTHON_DECL registration const* query(type_info);
30 BOOST_PYTHON_DECL void insert(to_python_function_t, type_info);
32 // Insert an lvalue from_python converter
33 BOOST_PYTHON_DECL void insert(void* (*convert)(PyObject*), type_info);
35 // Insert an rvalue from_python converter
36 BOOST_PYTHON_DECL void insert(
38 , constructor_function
42 // Insert an rvalue from_python converter at the tail of the
43 // chain. Used for implicit conversions
44 BOOST_PYTHON_DECL void push_back(
46 , constructor_function
51 }}} // namespace boost::python::converter
53 #endif // REGISTRY_DWA20011127_HPP