World Ocean Simulation System (WOSS) library
res-reader.h
Go to the documentation of this file.
1/* WOSS - World Ocean Simulation System -
2 *
3 * Copyright (C) 2009 2025 Federico Guerra
4 * and regents of the SIGNET lab, University of Padova
5 *
6 * Author: Federico Guerra - WOSS@guerra-tlc.com
7 *
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License version 2 as
10 * published by the Free Software Foundation;
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 */
21
22
33#ifndef WOSS_RES_READER_DEFINITIONS_H
34#define WOSS_RES_READER_DEFINITIONS_H
35
36
37#include <string>
40#include <memory>
41
42
43namespace woss {
44
45 class Woss;
46
52 class ResReader {
53
54 public:
55
60 ResReader( const Woss& woss );
61
62 virtual ~ResReader() = default;
63
68 virtual bool initialize() = 0;
69
80 virtual std::unique_ptr<Pressure> readAvgPressure( double frequency, double tx_depth, double start_rx_depth, double start_rx_range, double end_rx_depth, double end_rx_range ) = 0;
81
90 virtual std::unique_ptr<Pressure> readPressure( double frequency, double tx_depth, double rx_depth, double rx_range ) const = 0;
91
100 virtual std::unique_ptr<TimeArr> readTimeArr(double frequency, double tx_depth, double rx_depth, double rx_range ) const = 0;
101
106 const Woss& getWossRef() const { return woss_ref; }
107
113 ResReader& setFileName( const std::string& name ) { file_name = name; return *this; }
114
119 std::string getFileName() const { return file_name; }
120
121 protected:
122
127
131 std::string file_name;
132
133 };
134
135}
136
137#endif /* WOSS_RES_READER_DEFINITIONS_H */
Abstract class for channel simulator result files processing.
Definition res-reader.h:52
virtual std::unique_ptr< Pressure > readAvgPressure(double frequency, double tx_depth, double start_rx_depth, double start_rx_range, double end_rx_depth, double end_rx_range)=0
virtual std::unique_ptr< Pressure > readPressure(double frequency, double tx_depth, double rx_depth, double rx_range) const =0
virtual std::unique_ptr< TimeArr > readTimeArr(double frequency, double tx_depth, double rx_depth, double rx_range) const =0
std::string file_name
Definition res-reader.h:131
virtual bool initialize()=0
std::string getFileName() const
Definition res-reader.h:119
const Woss & woss_ref
Definition res-reader.h:126
const Woss & getWossRef() const
Definition res-reader.h:106
ResReader & setFileName(const std::string &name)
Definition res-reader.h:113
virtual ~ResReader()=default
Abstract class that provides the interface for initializing and running a channel simulator.
Definition woss.h:76
Definition ac-toolbox-arr-asc-reader.h:44
Definitions and library for woss::Pressure class.
Definitions and library for woss::TimeArr class.