Debian Codegraph @

src/atlas/util/DataType.cc

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 #include "DataType.h"
12
13 #include <sstream>
14
15 #include "atlas/runtime/Exception.h"
16
17 //------------------------------------------------------------------------------------------------------
18
19 namespace atlas {
20 namespace array {
21
22 void DataType::throw_not_recognised(kind_t kind) {
23 std::stringstream msg;
24 msg << "kind " << kind << " not recognised.";
25 throw_Exception(msg.str(), Here());
26 }
27
28 void DataType::throw_not_recognised(std::string datatype) {
29 std::stringstream msg;
30 msg << "datatype " << datatype << " not recognised.";
31 throw_Exception(msg.str(), Here());
32 }
33
34
35 //------------------------------------------------------------------------------------------------------
36
37 } // namespace array
38 } // namespace atlas