Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
Actor Framework
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
Actor Framework
Commits
a77b9138
Commit
a77b9138
authored
Aug 27, 2015
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rename safe/load to safe_state/load_state
parent
1aeaaf81
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
8 deletions
+8
-8
libcaf_core/caf/local_actor.hpp
libcaf_core/caf/local_actor.hpp
+2
-2
libcaf_core/caf/stateful_actor.hpp
libcaf_core/caf/stateful_actor.hpp
+2
-2
libcaf_core/src/local_actor.cpp
libcaf_core/src/local_actor.cpp
+4
-4
No files found.
libcaf_core/caf/local_actor.hpp
View file @
a77b9138
...
@@ -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 *
...
...
libcaf_core/caf/stateful_actor.hpp
View file @
a77b9138
...
@@ -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
);
}
}
...
...
libcaf_core/src/local_actor.cpp
View file @
a77b9138
...
@@ -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"
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment