Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: downloads/boost_1_34_1/boost/python/wrapper.hpp @ 29

Last change on this file since 29 was 29, checked in by landauf, 17 years ago

updated boost from 1_33_1 to 1_34_1

File size: 1023 bytes
Line 
1// Copyright David Abrahams 2004. Distributed under the Boost
2// Software License, Version 1.0. (See accompanying
3// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
4#ifndef WRAPPER_DWA2004720_HPP
5# define WRAPPER_DWA2004720_HPP
6
7# include <boost/python/detail/wrapper_base.hpp>
8# include <boost/python/override.hpp>
9# include <boost/python/converter/registered.hpp>
10# include <boost/python/detail/sfinae.hpp>
11
12namespace boost { namespace python { 
13
14template <class T>
15class wrapper : public detail::wrapper_base
16{
17 public:
18    // Do not touch this implementation detail!
19    typedef T _wrapper_wrapped_type_;
20
21 protected:
22    override get_override(char const* name) const
23    {
24        typedef detail::wrapper_base base;
25        converter::registration const& r
26            = converter::registered<T>::converters;
27        PyTypeObject* type = r.get_class_object();
28       
29        return this->base::get_override(name, type);
30    }
31};
32
33}} // namespace boost::python
34
35#endif // WRAPPER_DWA2004720_HPP
Note: See TracBrowser for help on using the repository browser.