Mantid
Loading...
Searching...
No Matches
Framework
PythonInterface
mantid
geometry
src
Exports
Container.cpp
Go to the documentation of this file.
1
// Mantid Repository : https://github.com/mantidproject/mantid
2
//
3
// Copyright © 2021 ISIS Rutherford Appleton Laboratory UKRI,
4
// NScD Oak Ridge National Laboratory, European Spallation Source,
5
// Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS
6
// SPDX - License - Identifier: GPL - 3.0 +
7
#include "
MantidGeometry/Instrument/Container.h
"
8
#include "
MantidPythonInterface/core/GetPointer.h
"
9
10
#include <boost/python/class.hpp>
11
#include <boost/python/register_ptr_to_python.hpp>
12
13
using
Mantid::Geometry::Container
;
14
using
Mantid::Geometry::IObject
;
15
using namespace
boost::python
;
16
17
GET_POINTER_SPECIALIZATION
(
Container
)
18
19
void
export_Container
() {
20
register_ptr_to_python<std::shared_ptr<Container>>();
21
22
class_<Container, boost::python::bases<IObject>, boost::noncopyable>(
"Container"
, no_init)
23
.def(
"getShape"
, &
Container::getShape
, arg(
"self"
),
"Returns a shape of a Sample object."
,
24
return_value_policy<reference_existing_object>());
25
}
Container.h
GetPointer.h
GET_POINTER_SPECIALIZATION
#define GET_POINTER_SPECIALIZATION(TYPE)
Definition:
GetPointer.h:17
export_Container
void export_Container()
Definition:
Container.cpp:19
Mantid::Geometry::Container
Models a Container is used to hold a sample in the beam.
Definition:
Container.h:24
Mantid::Geometry::Container::getShape
const IObject & getShape() const
Definition:
Container.h:42
Mantid::Geometry::IObject
IObject : Interface for geometry objects.
Definition:
IObject.h:41
boost::python
Definition:
NDArray.h:50
Generated on Tue Jan 3 2023 11:57:48 for Mantid by
1.9.5