Commit a2385933 authored by Georgios Dagkakis's avatar Georgios Dagkakis

cleanup unused attribute

parent 131045b3
...@@ -34,13 +34,15 @@ from ObjectInterruption import ObjectInterruption ...@@ -34,13 +34,15 @@ from ObjectInterruption import ObjectInterruption
class Break(ObjectInterruption): class Break(ObjectInterruption):
def __init__(self, id='',name='',victim=None, distribution={},deteriorationType='constant', def __init__(self, id='',name='',victim=None, distribution={},
endUnfinished=True,offShiftAnticipation=0,**kw): endUnfinished=True,offShiftAnticipation=0,**kw):
ObjectInterruption.__init__(self,id,name,victim=victim) ObjectInterruption.__init__(self,id,name,victim=victim)
self.rngTTB=RandomNumberGenerator(self, distribution.get('TTB',{'Fixed':{'mean':100}})) self.rngTTB=RandomNumberGenerator(self, distribution.get('TTB',{'Fixed':{'mean':100}}))
self.rngTTR=RandomNumberGenerator(self, distribution.get('TTR',{'Fixed':{'mean':10}})) self.rngTTR=RandomNumberGenerator(self, distribution.get('TTR',{'Fixed':{'mean':10}}))
self.type="Break" self.type="Break"
# end current wip before going to break
self.endUnfinished=endUnfinished self.endUnfinished=endUnfinished
# if the break is close to end of shift below a limit it will be suspended
self.offShiftAnticipation=offShiftAnticipation self.offShiftAnticipation=offShiftAnticipation
def initialize(self): def initialize(self):
......
...@@ -348,12 +348,11 @@ def createObjectInterruptions(): ...@@ -348,12 +348,11 @@ def createObjectInterruptions():
if br: if br:
victim=Globals.findObjectById(element['id']) victim=Globals.findObjectById(element['id'])
endUnfinished=bool(int(br.get('endUnfinished', 1))) endUnfinished=bool(int(br.get('endUnfinished', 1)))
deteriorationType=br.get('deteriorationType', 'constant')
offShiftAnticipation=br.get('offShiftAnticipation',0) offShiftAnticipation=br.get('offShiftAnticipation',0)
BR=Break(victim=victim, distribution=br,endUnfinished=endUnfinished,deteriorationType=deteriorationType, BR=Break(victim=victim, distribution=br,endUnfinished=endUnfinished,
offShiftAnticipation=offShiftAnticipation) offShiftAnticipation=offShiftAnticipation)
G.ObjectInterruptionList.append(BR) G.ObjectInterruptionList.append(BR)
G.FailureList.append(BR) G.BreakList.append(BR)
# =========================================================================== # ===========================================================================
# creates the entities that are wip # creates the entities that are wip
......
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