Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
batsim
batsim
Commits
80c27d89
Commit
80c27d89
authored
Apr 07, 2017
by
Millian Poquet
Browse files
[code] proto : simu_starts -> simu_begins...
parent
4518599e
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/protocol.cpp
View file @
80c27d89
...
...
@@ -108,11 +108,11 @@ void JsonProtocolWriter::append_query_request(void *anything,
void
JsonProtocolWriter
::
append_simulation_
start
s
(
double
date
)
void
JsonProtocolWriter
::
append_simulation_
begin
s
(
double
date
)
{
/* {
"timestamp": 0.0,
"type": "SIMULATION_
START
S",
"type": "SIMULATION_
BEGIN
S",
"data": {}
} */
...
...
@@ -121,7 +121,7 @@ void JsonProtocolWriter::append_simulation_starts(double date)
Value
event
(
rapidjson
::
kObjectType
);
event
.
AddMember
(
"timestamp"
,
Value
().
SetDouble
(
date
),
_alloc
);
event
.
AddMember
(
"type"
,
Value
().
SetString
(
"SIMULATION_
START
S"
),
_alloc
);
event
.
AddMember
(
"type"
,
Value
().
SetString
(
"SIMULATION_
BEGIN
S"
),
_alloc
);
event
.
AddMember
(
"data"
,
Value
().
SetObject
(),
_alloc
);
_events
.
PushBack
(
event
,
_alloc
);
...
...
@@ -313,12 +313,12 @@ bool test_json_writer()
printf
(
"NOP content:
\n
%s
\n
"
,
proto_writer
->
generate_current_message
(
42
).
c_str
());
proto_writer
->
clear
();
proto_writer
->
append_simulation_
start
s
(
10
);
printf
(
"SIM_
START
content:
\n
%s
\n
"
,
proto_writer
->
generate_current_message
(
42
).
c_str
());
proto_writer
->
append_simulation_
begin
s
(
10
);
printf
(
"SIM_
BEGINS
content:
\n
%s
\n
"
,
proto_writer
->
generate_current_message
(
42
).
c_str
());
proto_writer
->
clear
();
proto_writer
->
append_simulation_ends
(
10
);
printf
(
"SIM_END content:
\n
%s
\n
"
,
proto_writer
->
generate_current_message
(
42
).
c_str
());
printf
(
"SIM_END
S
content:
\n
%s
\n
"
,
proto_writer
->
generate_current_message
(
42
).
c_str
());
proto_writer
->
clear
();
proto_writer
->
append_job_submitted
({
"w0!j0"
,
"w0!j1"
},
10
);
...
...
src/protocol.hpp
View file @
80c27d89
...
...
@@ -125,7 +125,7 @@ public:
* @brief Appends a SIMULATION_STARTS event.
* @param[in] date The event date. Must be greater than or equal to the previous event.
*/
virtual
void
append_simulation_
start
s
(
double
date
)
=
0
;
virtual
void
append_simulation_
begin
s
(
double
date
)
=
0
;
/**
* @brief Appends a SIMULATION_ENDS event.
...
...
@@ -322,7 +322,7 @@ public:
* @brief Appends a SIMULATION_STARTS event.
* @param[in] date The event date. Must be greater than or equal to the previous event.
*/
void
append_simulation_
start
s
(
double
date
);
void
append_simulation_
begin
s
(
double
date
);
/**
* @brief Appends a SIMULATION_ENDS event.
...
...
Write
Preview
Supports
Markdown
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