|
ContactCenters V. 0.9.9. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectumontreal.iro.lecuyer.simevents.Event
umontreal.iro.lecuyer.contactcenters.msk.model.ShiftEvent
public class ShiftEvent
Represents a simulation event adding agents to a group
at the beginning of working parts of a shift, and removing
them at the end of working parts.
The agents to be added or removed are stored into
an internal array of Agent
objects
so the agents are reused from parts to parts of
a given shift.
Field Summary |
---|
Fields inherited from class umontreal.iro.lecuyer.simevents.Event |
---|
eventTime, priority, sim |
Constructor Summary | |
---|---|
ShiftEvent(DetailedAgentGroup group,
Agent[] agents,
ScheduleShift shift)
Similar to ShiftEvent(DetailedAgentGroup,ScheduleShift) ,
except that the agents in array agents are
added and removed to the group rather than an array of
new Agent objects. |
|
ShiftEvent(DetailedAgentGroup group,
ScheduleShift shift)
Constructs a new shift event managing agent group group, and using information in shift shift. |
Method Summary | |
---|---|
void |
actions()
|
void |
init(RandomStream stream,
double mult)
Initializes this event with a new multiplier mult, and resets the internal part index. |
void |
schedule()
Schedules this event to occur at the next time it is needed to add or remove the associated agents from the attached group. |
Methods inherited from class umontreal.iro.lecuyer.simevents.Event |
---|
cancel, cancel, compareTo, getRa, priority, reschedule, schedule, scheduleAfter, scheduleBefore, scheduleNext, setPriority, setRa, setSimulator, setTime, simulator, time |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ShiftEvent(DetailedAgentGroup group, ScheduleShift shift)
group
- the agent group to which agents are added and removed.shift
- the shift used to determine the number of
agents and working parts.public ShiftEvent(DetailedAgentGroup group, Agent[] agents, ScheduleShift shift)
ShiftEvent(DetailedAgentGroup,ScheduleShift)
,
except that the agents in array agents are
added and removed to the group rather than an array of
new Agent
objects.
Method Detail |
---|
public void init(RandomStream stream, double mult)
Agent
objects which are added and
removed from the associated group each time
the event occurs.
The array of agents is created or updated only if it does
not exist yet, or if its
length does not correspond to the
effective number of agents on the shift.
stream
- a random stream used to generate the number
of agents when it is random.mult
- the multiplier for the number of agents.
IllegalArgumentException
- if mult is negative.public void schedule()
init(RandomStream,double)
can be used to reset the event.
public void actions()
actions
in class Event
|
ContactCenters V. 0.9.9. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |