NeoN
A framework for CFD software
Loading...
Searching...
No Matches
copyTo.hpp
Go to the documentation of this file.
1// SPDX-FileCopyrightText: 2025 - 2026 NeoN authors
2//
3// SPDX-License-Identifier: MIT
4
5#pragma once
6
8
9namespace NeoN
10{
11
18template<typename HostType>
20{
21
22public:
23
24 virtual ~SupportsCopyTo() = default;
25
26 [[nodiscard]] virtual HostType copyToExecutor(Executor exec) const = 0;
27
28 [[nodiscard]] HostType copyToHost() const { return copyToExecutor(SerialExecutor()); }
29};
30
31}
Reference executor for serial CPU execution.
MixinClass signaling copyTo is supported.
Definition copyTo.hpp:20
HostType copyToHost() const
Definition copyTo.hpp:28
virtual ~SupportsCopyTo()=default
virtual HostType copyToExecutor(Executor exec) const =0
Integer types used throughout NeoN.
Definition array.hpp:18
std::variant< SerialExecutor, CPUExecutor, GPUExecutor > Executor
Definition executor.hpp:20