14#include <boost/python/class.hpp>
15#include <boost/python/copy_const_reference.hpp>
16#include <boost/python/register_ptr_to_python.hpp>
17#include <boost/python/return_internal_reference.hpp>
38std::shared_ptr<MDFrame> getMDFrame(
const IMDDimension &self) {
51 PyErr_Warn(PyExc_DeprecationWarning,
".getName() is deprecated. Use .name instead.");
56 register_ptr_to_python<std::shared_ptr<IMDDimension>>();
58 class_<IMDDimension, boost::noncopyable>(
"IMDDimension", no_init)
59 .def(
"getName", &
getName, arg(
"self"),
60 "Return the name of the dimension "
61 "as can be displayed along the "
64 "Return the name of the dimension as can be displayed "
69 "Return the number of bins dimension have (an integrated has one). "
70 "A axis directed along dimension would have getNBins+1 axis points.")
72 "Return the number of bins boundaries (axis points) dimension have "
73 "(an integrated has two). "
74 "A axis directed along dimension would have getNBins+1 axis points.")
75 .def(
"getX", &
IMDDimension::getX, (arg(
"self"), arg(
"ind")),
"Return coordinate of the axis at the given index")
78 "Return a short name which identify the dimension among other "
80 "A dimension can be usually find by its ID and various ")
81 .def(
"getUnits", &getUnitsAsStr, arg(
"self"),
"Return the units associated with this dimension.")
82 .def(
"getMDFrame", &getMDFrame, arg(
"self"),
"Return the multidimensional frame for this dimension.");
#define GET_POINTER_SPECIALIZATION(TYPE)
void export_IMDDimension()
std::string getName(const IMDDimension &self)
#define GNU_DIAG_OFF(x)
This is a collection of macros for turning compiler warnings off in a controlled manner.
The class describes one dimension of multidimensional dataset representing an orthogonal dimension an...
virtual coord_t getMaximum() const =0
virtual coord_t getMinimum() const =0
virtual std::string getName() const =0
virtual const Geometry::MDFrame & getMDFrame() const =0
virtual const Kernel::UnitLabel getUnits() const =0
virtual const std::string & getDimensionId() const =0
short name which identify the dimension among other dimension.
virtual coord_t getBinWidth() const
virtual coord_t getX(size_t ind) const =0
virtual size_t getNBoundaries() const =0
virtual size_t getNBins() const =0
virtual MDFrame * clone() const =0
const AsciiString & ascii() const
Return an ascii label for unit.