Debian Codegraph @

src/atlas/mesh/actions/BuildXYZField.h

raw
1 /*
2 * (C) Copyright 2013 ECMWF.
3 *
4 * This software is licensed under the terms of the Apache Licence Version 2.0
5 * which can be obtained at http://www.apache.org/licenses/LICENSE-2.0.
6 * In applying this licence, ECMWF does not waive the privileges and immunities
7 * granted to it by virtue of its status as an intergovernmental organisation
8 * nor does it submit to any jurisdiction.
9 */
10
11 #pragma once
12
13 #include <string>
14
15 namespace atlas {
16 class Field;
17 class Mesh;
18 } // namespace atlas
19
20 namespace atlas {
21 namespace mesh {
22 class Nodes;
23 }
24 } // namespace atlas
25
26 namespace atlas {
27 namespace mesh {
28 namespace actions {
29
30 //----------------------------------------------------------------------------------------------------------------------
31
32 /// Creates a XYZ field from the (lon,lat) field
33 class BuildXYZField {
34 public:
35 explicit BuildXYZField(const std::string& name = "xyz", bool force_recompute = false);
36
37 Field& operator()(Mesh&) const;
38 Field& operator()(mesh::Nodes&) const;
39
40 private:
41 std::string name_;
42 bool force_recompute_;
43 };
44
45 //----------------------------------------------------------------------------------------------------------------------
46
47 } // namespace actions
48 } // namespace mesh
49 } // namespace atlas