| Line | Branch | Exec | Source |
|---|---|---|---|
| 1 | // Copyright (C) 2026 Tiago V. L. Amorim (@tiagovla) | ||
| 2 | // | ||
| 3 | // This file is part of oiseau (https://github.com/tiagovla/oiseau) | ||
| 4 | // | ||
| 5 | // SPDX-License-Identifier: GPL-3.0-or-later | ||
| 6 | |||
| 7 | #pragma once | ||
| 8 | #include <cstddef> | ||
| 9 | #include <span> | ||
| 10 | #include <vector> | ||
| 11 | |||
| 12 | namespace oiseau::mesh { | ||
| 13 | class Geometry { | ||
| 14 | public: | ||
| 15 | Geometry(); | ||
| 16 | Geometry(std::vector<double>&& x, unsigned dim); | ||
| 17 | 47 | Geometry(Geometry&&) = default; | |
| 18 | 1 | Geometry(const Geometry&) = default; | |
| 19 | Geometry& operator=(Geometry&&) = default; | ||
| 20 | Geometry& operator=(const Geometry&) = default; | ||
| 21 | ~Geometry(); | ||
| 22 | |||
| 23 | std::span<double> x(); | ||
| 24 | std::span<const double> x() const; | ||
| 25 | std::span<double> x_at(std::size_t pos); | ||
| 26 | unsigned dim() const; | ||
| 27 | |||
| 28 | private: | ||
| 29 | std::vector<double> m_x; | ||
| 30 | unsigned m_dim = 3; | ||
| 31 | }; | ||
| 32 | } // namespace oiseau::mesh | ||
| 33 |