File hasghostmethod.h
File List > algebra > helpers > hasghostmethod.h
Go to the documentation of this file
#ifndef TEMPLAT_LATTICE_ALGEBRA_HELPERS_HASGHOSTMETHOD_H
#define TEMPLAT_LATTICE_ALGEBRA_HELPERS_HASGHOSTMETHOD_H
/* This file is part of TempLat, available at https://cosmolattice.github.io/templat .
Copyright 2021-2026 The TempLat authors, see AUTHORS.md.
Released under the MIT license, see LICENSE.md. */
// File info: Main contributor(s): Wessel Valkenburg, Franz R. Sattler, Year: 2026
#include "TempLat/util/rangeiteration/tag.h"
// #include "TempLat/lattice/field/fieldshiftedviewdetection.h"
namespace TempLat
{
template <class T>
concept HasGhostMethod = requires(std::decay_t<T> t) { t.confirmGhostsUpToDate(); };
template <int N, class T>
concept HasGhostMethodIndexed = requires(std::decay_t<T> t, Tag<N> tag) { t.confirmGhostsUpToDate(tag); };
template <class T>
concept HasGhostMethodDirectIndexed = requires(std::decay_t<T> t, device::Idx i) { t.confirmGhostsUpToDate(i); };
template <int N, class T>
concept HasGhostMethodElement = requires(std::decay_t<T> t, Tag<N> tag) { t(tag).confirmGhostsUpToDate(); };
template <class T>
concept HasGhostMethodDirectElement = requires(std::decay_t<T> t, device::Idx i) { t(i).confirmGhostsUpToDate(); };
} // namespace TempLat
#endif