DATRW++ library: seismic data I/O with multiple formats
reservoir.cc
Go to the documentation of this file.
1 /*! \file reservoir.cc
2  * \brief series reservoir (implementation)
3  *
4  * ----------------------------------------------------------------------------
5  *
6  * \author Thomas Forbriger
7  * \date 20/02/2010
8  *
9  * series reservoir (implementation)
10  *
11  * Copyright (c) 2010 by Thomas Forbriger (BFO Schiltach)
12  *
13  * ----
14  * This program is free software; you can redistribute it and/or modify
15  * it under the terms of the GNU General Public License as published by
16  * the Free Software Foundation; either version 2 of the License, or
17  * (at your option) any later version.
18  *
19  * This program is distributed in the hope that it will be useful,
20  * but WITHOUT ANY WARRANTY; without even the implied warranty of
21  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22  * GNU General Public License for more details.
23  *
24  * You should have received a copy of the GNU General Public License
25  * along with this program; if not, write to the Free Software
26  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
27  * ----
28  *
29  * REVISIONS and CHANGES
30  * - 20/02/2010 V1.0 Thomas Forbriger
31  *
32  * ============================================================================
33  */
34 #define DATRW_RESERVOIR_CC_VERSION \
35  "DATRW_RESERVOIR_CC V1.0"
36 
37 #include <datrwxx/reservoir.h>
38 #include <datrwxx/error.h>
39 
40 namespace datrw {
41 
42  namespace util {
43 
45  {
47  } // seriesreservoir::seriesreservoir()
48 
49  seriesreservoir::seriesreservoir(const Tdseries::Tcoc& series)
50  {
52  Mdseries=series.copyout();
53  } // seriesreservoir::seriesreservoir(const Tdseries& series)
54 
55  seriesreservoir::seriesreservoir(const Tfseries::Tcoc& series)
56  {
58  Mfseries=series.copyout();
59  } // seriesreservoir::seriesreservoir(const Tfseries& series)
60 
61  seriesreservoir::seriesreservoir(const Tiseries::Tcoc& series)
62  {
64  Miseries=series.copyout();
65  } // seriesreservoir::seriesreservoir(const Tiseries& series)
66 
67  Tdseries::Tcoc seriesreservoir::dseries() const
68  {
69  DATRW_assert((Mvaluetype == Fdouble), "wrong data type");
70  return Mdseries;
71  } // Tdseries seriesreservoir::dseries() const
72 
73  Tfseries::Tcoc seriesreservoir::fseries() const
74  {
75  DATRW_assert((Mvaluetype == Ffloat), "wrong data type");
76  return Mfseries;
77  } // Tfseries seriesreservoir::fseries() const
78 
79  Tiseries::Tcoc seriesreservoir::iseries() const
80  {
81  DATRW_assert((Mvaluetype == Finteger), "wrong data type");
82  return Miseries;
83  } // Tiseries seriesreservoir::iseries() const
84 
85  } // namespace util
86 
87 } // namespace datrw
88 
89 /* ----- END OF reservoir.cc ----- */
#define DATRW_assert(C, M)
Check an assertion and report by throwing an exception.
Definition: error.h:92
Tfseries::Tcoc Mfseries
Definition: reservoir.h:83
exception class declaration for libdatrwxx (prototypes)
Root namespace of library.
Definition: aalibdatrwxx.cc:16
single precision floating point
Definition: reservoir.h:55
Tdseries::Tcoc dseries() const
Definition: reservoir.cc:67
double precision floating point
Definition: reservoir.h:54
series reservoir (prototypes)
Tiseries::Tcoc Miseries
Definition: reservoir.h:84
Tiseries::Tcoc iseries() const
Definition: reservoir.cc:79
empty reservoir
Definition: reservoir.h:53
Tdseries::Tcoc Mdseries
Definition: reservoir.h:82
Tfseries::Tcoc fseries() const
Definition: reservoir.cc:73