opm-common
Toggle main menu visibility
Loading...
Searching...
No Matches
ColumnSchema.hpp
1
/*
2
Copyright 2015 Statoil ASA.
3
4
This file is part of the Open Porous Media project (OPM).
5
6
OPM is free software: you can redistribute it and/or modify
7
it under the terms of the GNU General Public License as published by
8
the Free Software Foundation, either version 3 of the License, or
9
(at your option) any later version.
10
11
OPM is distributed in the hope that it will be useful,
12
but WITHOUT ANY WARRANTY; without even the implied warranty of
13
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
GNU General Public License for more details.
15
16
You should have received a copy of the GNU General Public License
17
along with OPM. If not, see <http://www.gnu.org/licenses/>.
18
*/
19
20
21
#ifndef OPM_COLUMN_SCHEMA_HPP
22
#define OPM_COLUMN_SCHEMA_HPP
23
24
#include <string>
25
#include <vector>
26
27
#include <opm/input/eclipse/EclipseState/Tables/TableEnums.hpp>
28
29
namespace
Opm
{
30
31
class
ColumnSchema {
32
public
:
33
ColumnSchema();
34
ColumnSchema(
const
std::string& name , Table::ColumnOrderEnum order, Table::DefaultAction defaultAction);
35
ColumnSchema(
const
std::string& name , Table::ColumnOrderEnum order,
double
defaultValue);
36
37
static
ColumnSchema serializationTestObject();
38
39
const
std::string& name()
const
;
40
std::string orderSchema()
const
;
41
bool
validOrder(
double
value1 ,
double
value2)
const
;
42
bool
lookupValid( )
const
;
43
bool
acceptsDefault( )
const
;
44
bool
isIncreasing( )
const
;
45
bool
isDecreasing( )
const
;
46
Table::DefaultAction getDefaultMode( )
const
;
47
double
getDefaultValue( )
const
;
48
49
bool
operator==(
const
ColumnSchema& data)
const
;
50
51
template
<
class
Serializer>
52
void
serializeOp(
Serializer
& serializer)
53
{
54
serializer(m_name);
55
serializer(m_order);
56
serializer(m_defaultAction);
57
serializer(m_defaultValue);
58
}
59
60
private
:
61
std::string m_name;
62
Table::ColumnOrderEnum m_order;
63
Table::DefaultAction m_defaultAction;
64
double
m_defaultValue;
65
};
66
}
67
68
#endif
Opm::Serializer
Class for (de-)serializing.
Definition
Serializer.hpp:94
Opm
This class implements a small container which holds the transmissibility mulitpliers for all the face...
Definition
Exceptions.hpp:30
opm
input
eclipse
EclipseState
Tables
ColumnSchema.hpp
Generated by
1.17.0