UFO
ObsFunction.cc
Go to the documentation of this file.
1 /*
2  * (C) Copyright 2019 UCAR
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  */
7 
9 
10 #include "ioda/ObsDataVector.h"
11 #include "oops/util/DateTime.h"
12 #include "ufo/filters/Variables.h"
13 
14 namespace ufo {
15 
16 // -----------------------------------------------------------------------------
17 
18 template <typename FunctionValue>
20  : obsfct_(ObsFunctionFactory<FunctionValue>::create(var))
21 {}
22 
23 // -----------------------------------------------------------------------------
24 
25 template <typename FunctionValue>
27 
28 // -----------------------------------------------------------------------------
29 
30 template <typename FunctionValue>
33  obsfct_->compute(in, out);
34 }
35 
36 // -----------------------------------------------------------------------------
37 
38 template <typename FunctionValue>
40  return obsfct_->requiredVariables();
41 }
42 
43 // -----------------------------------------------------------------------------
44 
45 // Explicit instantiations for the supported value types
46 template class ObsFunction<float>;
47 template class ObsFunction<int>;
48 template class ObsFunction<std::string>;
49 template class ObsFunction<util::DateTime>;
50 
51 // -----------------------------------------------------------------------------
52 
53 } // namespace ufo
ObsFilterData provides access to all data related to an ObsFilter.
Factory of ObsFunctions producing values of type FunctionValue.
A function of observation data.
void compute(const ObsFilterData &, ioda::ObsDataVector< FunctionValue > &) const
compute(metadata, obs values, output)
Definition: ObsFunction.cc:31
const ufo::Variables & requiredVariables() const
required variables
Definition: ObsFunction.cc:39
ObsFunction(const Variable &)
constructor takes function name (for factory) on input
Definition: ObsFunction.cc:19
Definition: RunCRTM.h:27