aboutsummaryrefslogtreecommitdiff
path: root/paludis/resolver/arrow.cc
diff options
context:
space:
mode:
Diffstat (limited to 'paludis/resolver/arrow.cc')
-rw-r--r--paludis/resolver/arrow.cc21
1 files changed, 21 insertions, 0 deletions
diff --git a/paludis/resolver/arrow.cc b/paludis/resolver/arrow.cc
index 5b745cd..d8f58ab 100644
--- a/paludis/resolver/arrow.cc
+++ b/paludis/resolver/arrow.cc
@@ -18,8 +18,10 @@
*/
#include <paludis/resolver/arrow.hh>
+#include <paludis/resolver/serialise-impl.hh>
#include <paludis/util/sequence-impl.hh>
#include <paludis/util/wrapped_forward_iterator-impl.hh>
+#include <paludis/util/make_named_values.hh>
using namespace paludis;
using namespace paludis::resolver;
@@ -34,6 +36,25 @@ paludis::resolver::operator<< (std::ostream & s, const Arrow & a)
return s;
}
+void
+Arrow::serialise(Serialiser & s) const
+{
+ s.object("Arrow")
+ .member(SerialiserFlags<>(), "ignorable_pass", ignorable_pass())
+ .member(SerialiserFlags<>(), "to_qpn_s", to_qpn_s())
+ ;
+}
+
+const std::tr1::shared_ptr<Arrow>
+Arrow::deserialise(Deserialisation & d)
+{
+ Deserialisator v(d, "Arrow");
+ return make_shared_ptr(new Arrow(make_named_values<Arrow>(
+ value_for<n::ignorable_pass>(v.member<bool>("ignorable_pass")),
+ value_for<n::to_qpn_s>(v.member<QPN_S>("to_qpn_s"))
+ )));
+}
+
template class Sequence<std::tr1::shared_ptr<Arrow> >;
template class WrappedForwardIterator<ArrowSequence::ConstIteratorTag, const std::tr1::shared_ptr<Arrow> >;