Commit a77b9138 authored by Dominik Charousset's avatar Dominik Charousset

Rename safe/load to safe_state/load_state

parent 1aeaaf81
...@@ -397,12 +397,12 @@ public: ...@@ -397,12 +397,12 @@ public:
/// Serializes the state of this actor to `sink`. This function is /// Serializes the state of this actor to `sink`. This function is
/// only called if this actor has set the `is_serializable` flag. /// only called if this actor has set the `is_serializable` flag.
/// The default implementation throws a `std::logic_error`. /// The default implementation throws a `std::logic_error`.
virtual void save(serializer& sink, const unsigned int version); virtual void save_state(serializer& sink, const unsigned int version);
/// Deserializes the state of this actor from `source`. This function is /// Deserializes the state of this actor from `source`. This function is
/// only called if this actor has set the `is_serializable` flag. /// only called if this actor has set the `is_serializable` flag.
/// The default implementation throws a `std::logic_error`. /// The default implementation throws a `std::logic_error`.
virtual void load(deserializer& source, const unsigned int version); virtual void load_state(deserializer& source, const unsigned int version);
/**************************************************************************** /****************************************************************************
* deprecated member functions * * deprecated member functions *
......
...@@ -67,11 +67,11 @@ public: ...@@ -67,11 +67,11 @@ public:
return get_name(state_); return get_name(state_);
} }
void save(serializer& sink, const unsigned int version) override { void save_state(serializer& sink, const unsigned int version) override {
serialize_state(sink, state, version); serialize_state(sink, state, version);
} }
void load(deserializer& source, const unsigned int version) override { void load_state(deserializer& source, const unsigned int version) override {
serialize_state(source, state, version); serialize_state(source, state, version);
} }
......
...@@ -211,7 +211,7 @@ msg_type filter_msg(local_actor* self, mailbox_element& node) { ...@@ -211,7 +211,7 @@ msg_type filter_msg(local_actor* self, mailbox_element& node) {
} }
std::vector<char> buf; std::vector<char> buf;
binary_serializer bs{std::back_inserter(buf)}; binary_serializer bs{std::back_inserter(buf)};
self->save(bs, 0); self->save_state(bs, 0);
auto sender = node.sender; auto sender = node.sender;
// sync_send(...) // sync_send(...)
auto req = self->sync_send_impl(message_priority::normal, mm, auto req = self->sync_send_impl(message_priority::normal, mm,
...@@ -258,7 +258,7 @@ msg_type filter_msg(local_actor* self, mailbox_element& node) { ...@@ -258,7 +258,7 @@ msg_type filter_msg(local_actor* self, mailbox_element& node) {
self->is_migrated_from(false); self->is_migrated_from(false);
} }
binary_deserializer bd{buf.data(), buf.size()}; binary_deserializer bd{buf.data(), buf.size()};
self->load(bd, 0); self->load_state(bd, 0);
node.sender->enqueue( node.sender->enqueue(
mailbox_element::make_joint(self->address(), node.mid.response_id(), mailbox_element::make_joint(self->address(), node.mid.response_id(),
ok_atom::value, self->address()), ok_atom::value, self->address()),
...@@ -921,11 +921,11 @@ const char* local_actor::name() const { ...@@ -921,11 +921,11 @@ const char* local_actor::name() const {
return "actor"; return "actor";
} }
void local_actor::save(serializer&, const unsigned int) { void local_actor::save_state(serializer&, const unsigned int) {
throw std::logic_error("local_actor::serialize called"); throw std::logic_error("local_actor::serialize called");
} }
void local_actor::load(deserializer&, const unsigned int) { void local_actor::load_state(deserializer&, const unsigned int) {
throw std::logic_error("local_actor::deserialize called"); throw std::logic_error("local_actor::deserialize called");
} }
......
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