rexlib 0.1.0
Device-agnostic array computing library for CryoEM and CryoET image processing, with a pluggable backend architecture
Loading...
Searching...
No Matches
fixed_type_transform.hpp
1// SPDX-License-Identifier: GPL-3.0-only
2
3#pragma once
4
5#include <rexlib/core/numerical/numerical_type.hpp>
6#include <rexlib/core/numerical/numerical_type_domain_tags.hpp>
7#include <rexlib/core/numerical/numerical_type_traits.hpp>
8
9namespace rexlib
10{
11
22template <numerical_type Type>
24{
26
32 static const char* get_relation() noexcept;
33
41
49 {
50 using type = typename native_type_of<Type>::type;
51 };
52};
53
54} // namespace rexlib
55
56#include "fixed_type_transform.inl"
Container for multidimensional numeric data.
Definition array.hpp:31
Arrays, the operations on them and the devices that run those operations.
Definition cpu_device.hpp:10
numerical_type
Representation of all considered numerical types for computations.
Definition numerical_type.hpp:19
Named domain holding every representable type.
Definition numerical_type_domain_tags.hpp:199
Apply the transform to a native pivot type.
Definition fixed_type_transform.hpp:49
Transform ignoring the pivot and yielding a fixed type.
Definition fixed_type_transform.hpp:24
static const char * get_relation() noexcept
Get a fragment naming the mapping, for diagnostics.
static numerical_type apply(numerical_type type) noexcept
Apply the transform to a pivot type.
Convert numerical_type-s to static types.
Definition numerical_type_traits.hpp:141