GEOS
SimpleGeometricObjectBase.hpp
1 /*
2  * ------------------------------------------------------------------------------------------------------------
3  * SPDX-License-Identifier: LGPL-2.1-only
4  *
5  * Copyright (c) 2016-2024 Lawrence Livermore National Security LLC
6  * Copyright (c) 2018-2024 TotalEnergies
7  * Copyright (c) 2018-2024 The Board of Trustees of the Leland Stanford Junior University
8  * Copyright (c) 2023-2024 Chevron
9  * Copyright (c) 2019- GEOS/GEOSX Contributors
10  * All rights reserved
11  *
12  * See top level LICENSE, COPYRIGHT, CONTRIBUTORS, NOTICE, and ACKNOWLEDGEMENTS files for details.
13  * ------------------------------------------------------------------------------------------------------------
14  */
15 
16 /*
17  * @file SimpleGeometricObjectBase.hpp
18  */
19 
20 #ifndef GEOS_MESH_SIMPLEGEOMETRICOBJECTS_SIMPLEGEOMETRICOBJECTBASE_HPP_
21 #define GEOS_MESH_SIMPLEGEOMETRICOBJECTS_SIMPLEGEOMETRICOBJECTBASE_HPP_
22 
23 #include "dataRepository/Group.hpp"
26 
27 class Function;
28 
29 namespace geos
30 {
31 namespace dataRepository
32 {
33 namespace keys
34 {
35 string const geometricObjects( "GeometricObjects" );
36 }
37 }
38 
44 {
45 public:
46 
52  explicit SimpleGeometricObjectBase( string const & name,
53  Group * const parent );
54 
59 
64  static string catalogName() { return "SimpleGeometricObjectBase"; }
65 
70 
75 
77 
83  virtual bool isCoordInObject( real64 const ( &coord ) [3] ) const = 0;
84 
86  struct viewKeyStruct
87  {
89  static constexpr char const * epsilonString() { return "epsilon"; }
90  };
92 
93 protected:
94 
95  virtual void postInputInitialization() override;
96 
99 
100 };
101 
102 
103 }
104 #endif /* GEOS_MESH_SIMPLEGEOMETRICOBJECTS_SIMPLEGEOMETRICOBJECTBASE_HPP_ */
Base class for the geometric objects (box, plane, cylinder).
SimpleGeometricObjectBase(string const &name, Group *const parent)
Constructor.
static CatalogInterface::CatalogType & getCatalog()
Get the catalog name.
virtual void postInputInitialization() override
static string catalogName()
Get the catalog name.
virtual bool isCoordInObject(real64 const (&coord)[3]) const =0
Check if the input coordinates are in the object.
real64 m_epsilon
Tolerance for coordinate checks.
This class provides the base class/interface for the catalog value objects.
std::unordered_map< std::string, std::unique_ptr< CatalogInterface< BASETYPE, ARGS... > > > CatalogType
This is the type that will be used for the catalog. The catalog is actually instantiated in the BASET...
double real64
64-bit floating point type.
Definition: DataTypes.hpp:98
Structure to hold scoped key names.
Definition: Group.hpp:1444