~ubuntu-branches/ubuntu/saucy/python-demgengeo/saucy

« back to all changes in this revision

Viewing changes to Python/DifferenceVolPy.cc

  • Committer: Package Import Robot
  • Author(s): Anton Gladky
  • Date: 2011-11-18 21:47:18 UTC
  • Revision ID: package-import@ubuntu.com-20111118214718-4ysqm3dhpqwdd7gd
Tags: upstream-0.99~bzr106
ImportĀ upstreamĀ versionĀ 0.99~bzr106

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/////////////////////////////////////////////////////////////
 
2
//                                                         //
 
3
// Copyright (c) 2007-2011 by The University of Queensland //
 
4
// Earth Systems Science Computational Centre (ESSCC)      //
 
5
// http://www.uq.edu.au/esscc                              //
 
6
//                                                         //
 
7
// Primary Business: Brisbane, Queensland, Australia       //
 
8
// Licensed under the Open Software License version 3.0    //
 
9
// http://www.opensource.org/licenses/osl-3.0.php          //
 
10
//                                                         //
 
11
/////////////////////////////////////////////////////////////
 
12
 
 
13
#include <boost/version.hpp>
 
14
#include "DifferenceVolPy.h"
 
15
 
 
16
using namespace boost::python;
 
17
 
 
18
    void exportDifferenceVol()
 
19
    {
 
20
      // Check that Boost 1.34.0 or higher is being used.
 
21
      // If so, disable auto-generation of C++ signatures for Epydoc
 
22
      // (which stumbles over indentation in the auto-generated strings).
 
23
      #if ((BOOST_VERSION / 100000 >= 1) \
 
24
          && (BOOST_VERSION / 100 % 1000 >= 34)) \
 
25
          || (BOOST_VERSION / 100000 >= 2)
 
26
        boost::python::docstring_options no_autogen(true,false);
 
27
      #endif
 
28
 
 
29
      class_<DifferenceVol, bases<AVolume3D> >(
 
30
        "DifferenceVol",
 
31
        "A class defining a volume consisting of the difference of two volumes in 3D.",
 
32
        init<>()
 
33
      )
 
34
      .def(init<const DifferenceVol &>())
 
35
      .def(
 
36
        init<AVolume3D&,AVolume3D&>(
 
37
          ( arg("volume1"), arg("volume2") ),
 
38
          "Constructs a volume comprised of the difference of two volumes.\n"
 
39
          "The volume to be packed is all points within the first volume that are not also in the second volume.\n"
 
40
          "@type volume1: L{AVolume3D}\n"
 
41
          "@kwarg volume1: The first volume comprising the difference\n"
 
42
          "@type volume2: L{AVolume3D}\n"
 
43
          "@kwarg volume2: The second volume comprising the difference\n"
 
44
        )
 
45
      )
 
46
      .def(self_ns::str(self))
 
47
      ;
 
48
    }
 
49
 
 
50
 
 
51