26 #ifndef PDI_DATATYPE_H_ 27 #define PDI_DATATYPE_H_ 34 #include <pdi/pdi_fwd.h> 35 #include <pdi/datatype_template.h> 60 virtual std::pair<void*, Datatype_uptr> access(
const Array_datatype& type,
62 std::vector<std::unique_ptr<Accessor_base>>::const_iterator remaining_begin,
63 std::vector<std::unique_ptr<Accessor_base>>::const_iterator remaining_end)
const;
74 std::vector<std::unique_ptr<Accessor_base>>::const_iterator remaining_begin,
75 std::vector<std::unique_ptr<Accessor_base>>::const_iterator remaining_end)
const;
84 virtual std::pair<void*, Datatype_uptr> access(
const Record_datatype& type,
86 std::vector<std::unique_ptr<Accessor_base>>::const_iterator remaining_begin,
87 std::vector<std::unique_ptr<Accessor_base>>::const_iterator remaining_end)
const;
92 virtual std::string access_kind()
const = 0;
97 virtual std::unique_ptr<Accessor_base> clone()
const = 0;
117 virtual bool operator== (
const Datatype& other)
const = 0;
124 bool operator!=(
const Datatype& other)
const;
136 virtual bool dense()
const = 0;
143 virtual size_t datasize()
const = 0;
150 virtual size_t buffersize()
const = 0;
156 virtual size_t alignment()
const = 0;
163 virtual bool simple()
const = 0;
172 virtual void* data_to_dense_copy(
void* to,
const void* from)
const = 0;
181 virtual void* data_from_dense_copy(
void* to,
const void* from)
const = 0;
190 std::pair<void*, Datatype_uptr> subaccess(
void* from,
const Accessor_base& accessor)
const;
199 std::pair<void*, Datatype_uptr> subaccess(
void* from,
const std::vector<std::unique_ptr<Accessor_base>>& accessors)
const;
209 virtual std::pair<void*, Datatype_uptr> subaccess_by_iterators(
void* from,
210 std::vector<std::unique_ptr<Accessor_base>>::const_iterator remaining_begin,
211 std::vector<std::unique_ptr<Accessor_base>>::const_iterator remaining_end)
const;
218 virtual void destroy_data(
void* ptr)
const = 0;
224 virtual std::string debug_string()
const = 0;
230 #endif // PDI_DATATYPE_H_ A Datatype is a Datatype_template that accepts no argument.
Definition: datatype.h:46
Base class for datatype accesssors, that allow to get pointer to subtype.
Definition: datatype.h:52
an Array_datatype is a Datatype that represents an array: i.e storage of multiple elements of the sam...
Definition: array_datatype.h:43
Definition: pointer_datatype.h:37
std::unique_ptr< Datatype > Datatype_uptr
Definition: pdi_fwd.h:78
A Record_datatype is a Datatype that represents a fixed number of elements of potentially different t...
Definition: record_datatype.h:42
Definition: datatype_template.h:34
Definition: array_datatype.h:37