Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
dream
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
dream
Commits
00dcc743
Commit
00dcc743
authored
Sep 29, 2014
by
Ioannis Papagiannopoulos
Committed by
Georgios Dagkakis
Nov 03, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
release of load operator performed after getEntity. manual Operation defined in entities route fix
parent
5537ffb9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
5 deletions
+12
-5
dream/simulation/Machine.py
dream/simulation/Machine.py
+12
-5
No files found.
dream/simulation/Machine.py
View file @
00dcc743
...
...
@@ -637,11 +637,11 @@ class Machine(CoreObject):
#===================================================================
#===================================================================
#===================================================================
# # release a resource if the only operation type is Load
#===================================================================
if
self
.
shouldYield
(
operationTypes
=
{
"Load"
:
1
,
"Processing"
:
0
,
"Setup"
:
0
},
methods
=
{
'isOperated'
:
1
}):
yield
self
.
env
.
process
(
self
.
release
())
#
#===================================================================
#
# # release a resource if the only operation type is Load
#
#===================================================================
#
if self.shouldYield(operationTypes={"Load":1, "Processing":0,"Setup":0},methods={'isOperated':1}):
#
yield self.env.process(self.release())
#===================================================================
#===================================================================
...
...
@@ -663,6 +663,13 @@ class Machine(CoreObject):
# TODO: the Machine receive the entity after the operator is available
# the canAcceptAndIsRequested method checks only in case of Load type of operation
#===================================================================
# # release a resource if the only operation type is Load
#===================================================================
if
self
.
shouldYield
(
operationTypes
=
{
"Load"
:
1
,
"Processing"
:
0
,
"Setup"
:
0
},
methods
=
{
'isOperated'
:
1
}):
yield
self
.
env
.
process
(
self
.
release
())
#===================================================================
# # request a resource if it is not already assigned an Operator
#===================================================================
...
...
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