Maintenance - Mise à jour mensuelle Lundi 7 Décembre 2021 entre 7h00 et 9h00

Commit f6d0a59f authored by K-H-Ismail's avatar K-H-Ismail Committed by Gauthier Quesnel
Browse files

io: add accumulator_2 writer reader and adapt generator w/r

parent cd7f081d
......@@ -279,9 +279,11 @@ private:
return true;
}
bool read(generator& /*dyn*/) noexcept
bool read(generator& dyn) noexcept
{
return true;
return !!(is >> dyn.default_value >> dyn.default_period >>
dyn.default_offset);;
}
bool read(constant& dyn) noexcept
......@@ -294,6 +296,11 @@ private:
return !!(is >> dyn.default_threshold);
}
bool read(accumulator_2& /*dyn*/) noexcept
{
return true;
}
bool read(time_func& dyn) noexcept
{
if (!(is >> temp_1))
......@@ -455,9 +462,10 @@ private:
os << "counter\n";
}
void write(const generator& /*dyn*/) noexcept
void write(const generator& dyn) noexcept
{
os << "generator\n";
os << "generator"<< dyn.default_value << ' ' << dyn.default_period
<< ' ' << dyn.default_offset << '\n';;
}
void write(const constant& dyn) noexcept
......@@ -470,6 +478,11 @@ private:
os << "cross " << dyn.default_threshold << '\n';
}
void write(const accumulator_2& /*dyn*/) noexcept
{
os << "accumulator_2\n";
}
void write(const time_func& dyn) noexcept
{
os << "time_func "
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment