Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
NetworkedGraphicsMV3500
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Savage
NetworkedGraphicsMV3500
Commits
336b09df
Commit
336b09df
authored
3 years ago
by
Brutzman, Don
Browse files
Options
Downloads
Patches
Plain Diff
javadoc
parent
5936b1e7
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
examples/src/OpenDis7Examples/ExampleSimulationProgram.java
+5
-4
5 additions, 4 deletions
examples/src/OpenDis7Examples/ExampleSimulationProgram.java
with
5 additions
and
4 deletions
examples/src/OpenDis7Examples/ExampleSimulationProgram.java
+
5
−
4
View file @
336b09df
...
...
@@ -20,6 +20,7 @@ import java.util.logging.Logger;
* that includes DIS-capable entities performing tasks of interest, and then reporting activity via PDUs
* to the network.
* Default program initialization includes PDU recording turned on by default.
* @see <a href="https://gitlab.nps.edu/Savage/NetworkedGraphicsMV3500/-/blob/master/examples/src/OpenDis7Examples/ExampleSimulationProgramLog.txt">ExampleSimulationProgramLog.txt</a>
*/
public
class
ExampleSimulationProgram
{
...
...
@@ -38,13 +39,13 @@ public class ExampleSimulationProgram
double
simulationTime
;
/**
* Output prefix to identify this class (overrid
e
in subclass)
, helps with logging
* Output prefix to
help with logging by
identify
ing
this class (overrid
den
in subclass)
.
*/
protected
static
String
TRACE_PREFIX
;
/**
* This runSimulationLoops() method is for you, a programmer-modifiable
code block
* for defining and running a new simulation of interest.
* This runSimulationLoops() method is for you, a
customizable
programmer-modifiable
*
code block
for defining and running a new simulation of interest.
*
* Welcome! Other parts of this program handle bookkeeping and plumbing tasks so that
* you can focus on your model entities and activities.
...
...
@@ -151,7 +152,7 @@ public class ExampleSimulationProgram
// loop now finished, check whether to terminate if simulation complete, otherwise continue
if
(
simulationComplete
||
(
simulationLoopCount
>
10000
))
// for example; including fail-safe condition is good
{
System
.
out
.
println
(
"... [
T
ermination condition met, simulationComplete="
+
simulationComplete
+
"]"
);
// ", final loopCount=" + loopCount +
System
.
out
.
println
(
"... [
loop t
ermination condition met, simulationComplete="
+
simulationComplete
+
"]"
);
// ", final loopCount=" + loopCount +
break
;
}
}
// end of simulation loop
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment