IOLink
IOL_v1.1.0_release
Indexer.h
1
#pragma once
2
3
#include <iolink/DataType.h>
4
#include <iolink/MemoryLayout.h>
5
#include <iolink/VectorX.h>
6
7
namespace
iolink
8
{
9
35
class
IOLINK_API
Indexer
final
36
{
37
public
:
38
Indexer
();
39
52
Indexer
(
const
VectorXu64
& shape,
const
VectorXu64
& stride,
const
VectorXu64
& layout);
53
67
Indexer
(
const
VectorXu64
& shape,
const
VectorXu64
& stride,
MemoryLayout
standardLayout);
68
76
Indexer
(
const
VectorXu64
& shape,
const
VectorXu64
& layout);
77
86
Indexer
(
const
VectorXu64
& shape,
MemoryLayout
standardLayout);
87
96
explicit
Indexer
(
const
VectorXu64
& shape);
97
98
Indexer
(
const
Indexer
& other);
99
Indexer
& operator=(
const
Indexer
& other);
100
101
Indexer
(
Indexer
&& other) noexcept;
102
Indexer
& operator=(
Indexer
&& other) noexcept;
103
104
~
Indexer
();
105
109
size_t
dimensionCount()
const
;
110
114
const
VectorXu64
& shape()
const
;
115
119
const
VectorXu64
& stride()
const
;
120
124
const
VectorXu64
& layout()
const
;
125
131
size_t
shape(
size_t
index)
const
;
132
138
size_t
stride(
size_t
index)
const
;
139
145
size_t
layout(
size_t
index)
const
;
146
150
size_t
elementCount()
const
;
151
157
size_t
offset(
const
VectorXu64
& index)
const
;
158
159
private
:
160
class
Private;
161
Private* m_private;
162
};
163
164
}
// end namespace iolink
iolink::VectorX
A dynamically sized arithmetic vector.
Definition:
VectorX.h:17
iolink
All IOLink symbols are enclosed in this namespace.
Definition:
ArrayX.h:7
iolink::Indexer
This class is used to index a classic array into a multi dimensional array.
Definition:
Indexer.h:35
iolink::MemoryLayout
MemoryLayout
This enum indicates how a multidimensionnal array is stored in continuous memory.
Definition:
MemoryLayout.h:10
iolink
public
include
iolink
Indexer.h
Generated on Tue Apr 26 2022 13:38:47 for IOLink by
1.8.17