remove old serialization support for ActionX

This commit is contained in:
Arne Morten Kvarving 2020-03-17 15:40:52 +01:00
parent c5f36bd7cc
commit 2c1d45ea54
3 changed files with 1 additions and 59 deletions

View File

@ -25,7 +25,6 @@
#include <opm/parser/eclipse/EclipseState/Grid/FaceDir.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/Action/ActionAST.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/Action/Actions.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/Action/ActionX.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/Action/Condition.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/MSW/icd.hpp>
#include <opm/parser/eclipse/EclipseState/Schedule/MSW/SpiralICD.hpp>
@ -688,20 +687,6 @@ std::size_t packSize(const Action::Condition& data,
packSize(data.cmp_string, comm);
}
std::size_t packSize(const Action::ActionX& data,
Dune::MPIHelper::MPICommunicator comm)
{
return packSize(data.name(), comm) +
packSize(data.max_run(), comm) +
packSize(data.min_wait(), comm) +
packSize(data.start_time(), comm) +
packSize(data.getKeywords(), comm) +
packSize(data.getCondition(), comm) +
packSize(data.conditions(), comm) +
packSize(data.getRunCount(), comm) +
packSize(data.getLastRun(), comm);
}
std::size_t packSize(const Action::Actions& data,
Dune::MPIHelper::MPICommunicator comm)
{
@ -1374,21 +1359,6 @@ void pack(const Action::Condition& data,
pack(data.cmp_string, buffer, position, comm);
}
void pack(const Action::ActionX& data,
std::vector<char>& buffer, int& position,
Dune::MPIHelper::MPICommunicator comm)
{
pack(data.name(), buffer, position, comm);
pack(data.max_run(), buffer, position, comm);
pack(data.min_wait(), buffer, position, comm);
pack(data.start_time(), buffer, position, comm);
pack(data.getKeywords(), buffer, position, comm);
pack(data.getCondition(), buffer, position, comm);
pack(data.conditions(), buffer, position, comm);
pack(data.getRunCount(), buffer, position, comm);
pack(data.getLastRun(), buffer, position, comm);
}
void pack(const Action::Actions& data,
std::vector<char>& buffer, int& position,
Dune::MPIHelper::MPICommunicator comm)
@ -2298,32 +2268,6 @@ void unpack(Action::Condition& data, std::vector<char>& buffer, int& position,
unpack(data.cmp_string, buffer, position, comm);
}
void unpack(Action::ActionX& data, std::vector<char>& buffer, int& position,
Dune::MPIHelper::MPICommunicator comm)
{
std::string name;
size_t max_run;
double min_wait;
std::time_t start_time;
std::vector<DeckKeyword> keywords;
Action::AST condition;
std::vector<Action::Condition> conditions;
size_t run_count;
std::time_t last_run;
unpack(name, buffer, position, comm);
unpack(max_run, buffer, position, comm);
unpack(min_wait, buffer, position, comm);
unpack(start_time, buffer, position, comm);
unpack(keywords, buffer, position, comm);
unpack(condition, buffer, position, comm);
unpack(conditions, buffer, position, comm);
unpack(run_count, buffer, position, comm);
unpack(last_run, buffer, position, comm);
data = Action::ActionX(name, max_run, min_wait, start_time, keywords,
condition, conditions, run_count, last_run);
}
void unpack(Action::Actions& data, std::vector<char>& buffer, int& position,
Dune::MPIHelper::MPICommunicator comm)
{

View File

@ -45,7 +45,6 @@ namespace Opm
namespace Action {
class Actions;
class ActionX;
class AST;
class Condition;
class Quantity;
@ -388,7 +387,6 @@ void unpack(char* str, std::size_t length, std::vector<char>& buffer, int& posit
Dune::MPIHelper::MPICommunicator comm);
ADD_PACK_PROTOTYPES(Action::Actions)
ADD_PACK_PROTOTYPES(Action::ActionX)
ADD_PACK_PROTOTYPES(Action::AST)
ADD_PACK_PROTOTYPES(Action::Condition)
ADD_PACK_PROTOTYPES(Action::Quantity)

View File

@ -2040,7 +2040,7 @@ BOOST_AUTO_TEST_CASE(ActionX)
{
#ifdef HAVE_MPI
Opm::Action::ActionX val1 = getActionX();
auto val2 = PackUnpack(val1);
auto val2 = PackUnpack2(val1);
DO_CHECKS(Action::ActionX)
#endif
}