PISM, A Parallel Ice Sheet Model  stable v2.1-1-g6902d5502 committed by Ed Bueler on 2023-12-20 08:38:27 -0800
Factory.cc
Go to the documentation of this file.
1 /* Copyright (C) 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2023 PISM Authors
2  *
3  * This file is part of PISM.
4  *
5  * PISM is free software; you can redistribute it and/or modify it under the
6  * terms of the GNU General Public License as published by the Free Software
7  * Foundation; either version 3 of the License, or (at your option) any later
8  * version.
9  *
10  * PISM is distributed in the hope that it will be useful, but WITHOUT ANY
11  * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12  * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
13  * details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with PISM; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18  */
19 
20 #include "pism/coupler/surface/Factory.hh"
21 
22 // surface models:
23 #include "pism/coupler/surface/Anomaly.hh"
24 #include "pism/coupler/surface/Cache.hh"
25 #include "pism/coupler/surface/ConstantPIK.hh"
26 #include "pism/coupler/surface/Delta_T.hh"
27 #include "pism/coupler/surface/Elevation.hh"
28 #include "pism/coupler/surface/ElevationChange.hh"
29 #include "pism/coupler/surface/ForceThickness.hh"
30 #include "pism/coupler/surface/GivenClimate.hh"
31 #include "pism/coupler/surface/ISMIP6Climate.hh"
32 #include "pism/coupler/surface/NoGLRetreat.hh"
33 #include "pism/coupler/surface/DEBMSimple.hh"
34 #include "pism/coupler/surface/Simple.hh"
35 #include "pism/coupler/surface/TemperatureIndex.hh"
36 
37 namespace pism {
38 namespace surface {
39 
40 Factory::Factory(std::shared_ptr<const Grid> g, std::shared_ptr<atmosphere::AtmosphereModel> input)
41  : PCFactory<SurfaceModel>(g, "surface.models"),
42  m_input(input) {
43 
44  add_surface_model<Elevation>("elevation");
45  add_surface_model<Given>("given");
46  add_surface_model<ISMIP6>("ismip6");
47  add_surface_model<TemperatureIndex>("pdd");
48  add_surface_model<PIK>("pik");
49  add_surface_model<Simple>("simple");
50  add_surface_model<DEBMSimple>("debm_simple");
51 
52  add_modifier<Anomaly>("anomaly");
53  add_modifier<Cache>("cache");
54  add_modifier<Delta_T>("delta_T");
55  add_modifier<ForceThickness>("forcing");
56  add_modifier<ElevationChange>("elevation_change");
57  add_modifier<NoGLRetreat>("no_gl_retreat");
58 }
59 
60 } // end of namespace surface
61 } // end of namespace pism
Factory(std::shared_ptr< const Grid > g, AtmospherePtr input)
static const double g
Definition: exactTestP.cc:36