17namespace DataObjects {
34 MDBoxIterator(std::vector<API::IMDNode *> &boxes,
size_t begin,
size_t end);
35 void init(std::vector<API::IMDNode *> &boxes,
size_t begin,
size_t end);
42 size_t getDataSize()
const override;
44 bool valid()
const override;
46 void jumpTo(
size_t index)
override;
50 bool next(
size_t skip)
override;
52 signal_t getNormalizedSignal()
const override;
54 signal_t getNormalizedError()
const override;
60 std::unique_ptr<coord_t[]> getVertexesArray(
size_t &numVertices,
const size_t outDimensions,
61 const bool *maskDim)
const override;
63 std::unique_ptr<coord_t[]> getVertexesArray(
size_t &numVertices)
const override;
67 size_t getNumEvents()
const override;
69 uint16_t getInnerExpInfoIndex(
size_t index)
const override;
71 uint16_t getInnerGoniometerIndex(
size_t index)
const override;
73 int32_t getInnerDetectorID(
size_t index)
const override;
75 coord_t getInnerPosition(
size_t index,
size_t dimension)
const override;
81 bool getIsMasked()
const override;
86 std::vector<size_t> findNeighbourIndexes()
const override;
88 std::vector<size_t> findNeighbourIndexesFaceTouching()
const override;
90 size_t getLinearIndex()
const override;
92 bool isWithinBounds(
size_t index)
const override;
96 void commonConstruct(
API::IMDNode *topBox,
size_t maxDepth,
bool leafOnly,
99 void getEvents()
const;
101 void releaseEvents()
const;
std::map< DeltaEMode::Type, std::string > index
#define TMDE_CLASS
Macro to make declaring template classes faster.
This is an interface to an iterator of an IMDWorkspace.
Templated super-class of a multi-dimensional event "box".
MDBoxIterator: iterate through MDBoxBase hierarchy down to a given maximum depth.
MDBox< MDE, nd > * m_currentMDBox
MDBox currently pointed to.
size_t m_pos
Current position in the vector of boxes.
SkippingPolicy_scptr m_skippingPolicy
size_t getPosition() const
Getter for the position of the iterator.
MDBoxBase< MDE, nd > * m_current
Box currently pointed to.
MDBoxBase< MDE, nd > * getBox() const
Return a pointer to the current box pointed to by the iterator.
const std::vector< MDE > * m_events
Pointer to the const events vector. Only initialized when needed.
std::vector< API::IMDNode * > m_boxes
Vector of all the boxes that will be iterated.
size_t m_max
Max pos = length of the boxes vector.
Templated class for a multi-dimensional event "box".
SkippingPolicy : Policy types for skipping in MDiterators.
An "ImplicitFunction" defining a hyper-cuboid-shaped region in N dimensions.
boost::scoped_ptr< SkippingPolicy > SkippingPolicy_scptr
Helper class which provides the Collimation Length for SANS instruments.
float coord_t
Typedef for the data type to use for coordinate axes in MD objects such as MDBox, MDEventWorkspace,...
double signal_t
Typedef for the signal recorded in a MDBox, etc.