public class DELAY<J extends SimJob,Q extends DELAY> extends AbstractServerlessSimQueue<J,Q>
DELAY queue induces a fixed waiting delay, after which jobs depart without service.
This SimQueue is server-less.
Copyright (C) 2005-2017 Jan de Jongh, TNO
This file is covered by the LICENSE file in the root of this project.
ZEROAbstractSimEntity.Notifier, AbstractSimEntity.PreNotificationHookSimQueue.AutoRevocationPolicySimEntity.Action, SimEntity.UnknownNotificationTypePolicy, SimEntity.UnknownOperationPolicyeventsScheduled, SANITYUSE_ARRAY_OPTIMIZATION| Constructor and Description |
|---|
DELAY(org.javades.jsimulation.r5.SimEventList eventList,
double waitTime)
Creates a
DELAY queue with infinite buffer size given a (fixed) waiting time and an event list,. |
| Modifier and Type | Method and Description |
|---|---|
DELAY<J,Q> |
getCopySimQueue()
Returns a new
DELAY object on the same SimEventList with the same wait time. |
Object |
getQoS()
Calls super method (in order to make implementation final).
|
Class |
getQoSClass()
Calls super method (in order to make implementation final).
|
double |
getWaitTime()
Returns the wait time for all jobs.
|
protected void |
insertJobInQueueUponArrival(J job,
double time)
Does nothing.
|
protected void |
removeJobFromQueueUponDeparture(J departingJob,
double time)
Does nothing.
|
protected void |
removeJobFromQueueUponDrop(J job,
double time)
Throws
IllegalStateException. |
protected void |
removeJobFromQueueUponRevokation(J job,
double time,
boolean auto)
Cancels the departure of the job (if present).
|
protected void |
rescheduleAfterArrival(J job,
double time)
If needed, schedules a departure event for the arrived job respecting the fixed wait time of this queue;
otherwise (zero wait time), makes the job depart immediately.
|
protected void |
rescheduleAfterDeparture(J departedJob,
double time)
Does nothing.
|
protected void |
rescheduleAfterDrop(J job,
double time)
Throws
IllegalStateException. |
protected void |
rescheduleAfterRevokation(J job,
double time,
boolean auto)
Does nothing.
|
protected void |
resetEntitySubClass()
Calls super method (in order to make implementation final).
|
String |
toStringDefault()
Returns "DELAY[wait time]".
|
getServiceTimeForJob, insertJobInQueueUponStart, isStartArmed, queueAccessVacationDropSubClass, rescheduleAfterStart, rescheduleForNewServerAccessCredits, setServerAccessCreditsSubClassgetBufferSize, getNumberOfServersarrive, autoRevoke, cancelDepartureEvent, cancelDepartureEvent, depart, departureFromEventList, drop, getAutoRevocationPolicy, getDepartureEvents, getDepartureEvents, getFirstJob, getFirstJobInServiceArea, getFirstJobInWaitingArea, getJobs, getJobsInServiceArea, getJobsInWaitingArea, getNumberOfJobs, getNumberOfJobsInServiceArea, getNumberOfJobsInWaitingArea, getServerAccessCredits, hasJobs, hasJobsInServiceArea, hasJobsInWaitingArea, hasServerAcccessCredits, isJob, isJobInServiceArea, isJobInWaitingArea, isQueueAccessVacation, registerStdOutSimQueueListener, revoke, revoke, scheduleDepartureEvent, scheduleJobArrival, setAutoRevocationPolicy, setQueueAccessVacation, setServerAccessCredits, start, takeServerAccessCredit, triggerPotentialNewStartArmed, unregisterStdOutSimQueueListeneraddPendingNotification, addPendingNotification, clearAndUnlockPendingNotificationsIfLocked, delegateOperation, doAfterNotifications, doOperation, fireAndLockPendingNotifications, getEventList, getLastUpdateTime, getRegisteredDelegatedOperations, getRegisteredNotificationTypes, getRegisteredOperations, getSimEntityListeners, getUnknownNotificationTypePolicy, getUnknownOperationPolicy, isIgnoreEventListReset, notifyEventListReset, registerDelegatedOperation, registerNotificationType, registerOperation, registerPreEventHook, registerPreNotificationHook, registerPreUpdateHook, registerSimEntityListener, registerStdOutSimEntityListener, removeDelegationForOperation, resetEntity, setIgnoreEventListReset, setName, setUnknownNotificationTypePolicy, setUnknownOperationPolicy, toString, unregisterSimEntityListener, unregisterStdOutSimEntityListener, updateclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitarrive, getAutoRevocationPolicy, getJobs, getJobsInServiceArea, getJobsInWaitingArea, getNumberOfJobs, getNumberOfJobsInServiceArea, getNumberOfJobsInWaitingArea, getServerAccessCredits, isJob, isJobInServiceArea, isJobInWaitingArea, isQueueAccessVacation, revoke, revoke, setAutoRevocationPolicy, setQueueAccessVacation, setServerAccessCreditsdoAfterNotifications, doOperation, getEventList, getLastUpdateTime, getRegisteredNotificationTypes, getRegisteredOperations, getSimEntityListeners, getUnknownNotificationTypePolicy, getUnknownOperationPolicy, isIgnoreEventListReset, registerSimEntityListener, resetEntity, setIgnoreEventListReset, setName, setUnknownNotificationTypePolicy, setUnknownOperationPolicy, unregisterSimEntityListener, updatepublic DELAY(org.javades.jsimulation.r5.SimEventList eventList,
double waitTime)
DELAY queue with infinite buffer size given a (fixed) waiting time and an event list,.eventList - The event list to use.waitTime - The (fixed) wait time for all jobs.IllegalArgumentException - If waitTime is strictly negative.public DELAY<J,Q> getCopySimQueue()
DELAY object on the same SimEventList with the same wait time.DELAY object on the same SimEventList with the same wait time.AbstractSimEntity.getEventList(),
getWaitTime()public String toStringDefault()
toStringDefault in interface SimEntitytoStringDefault in class AbstractSimQueue<J extends SimJob,Q extends DELAY>SimEntity.setName(java.lang.String),
Object.toString()public final double getWaitTime()
public final Class getQoSClass()
null.public final Object getQoS()
null.protected final void resetEntitySubClass()
resetEntitySubClass in class AbstractSimQueue<J extends SimJob,Q extends DELAY>SimEntity.resetEntity()protected final void insertJobInQueueUponArrival(J job, double time)
insertJobInQueueUponArrival in class AbstractSimQueue<J extends SimJob,Q extends DELAY>job - The job that arrived.time - The current time (i.e., arrival time of the job).AbstractSimQueue.arrive(double, J),
AbstractSimQueue.rescheduleAfterArrival(J, double)protected final void rescheduleAfterArrival(J job, double time)
If the wait time is Double.POSITIVE_INFINITY, no departure events are scheduled, in other words,
this queue does not schedule departures at infinity.
rescheduleAfterArrival in class AbstractSimQueue<J extends SimJob,Q extends DELAY>job - The job that arrived (and is already present in AbstractSimQueue.getJobs()).time - The current time (i.e., the arrival time of the job).getWaitTime(),
AbstractSimQueue.scheduleDepartureEvent(double, J),
AbstractSimQueue.depart(double, J)protected final void removeJobFromQueueUponDrop(J job, double time)
IllegalStateException.removeJobFromQueueUponDrop in class AbstractSimQueue<J extends SimJob,Q extends DELAY>job - The job that is to be dropped.time - The current time (i.e., drop time of the job).IllegalStateException - Always, as a call to this method is unexpected.AbstractSimQueue.drop(J, double),
AbstractSimQueue.rescheduleAfterDrop(J, double)protected final void rescheduleAfterDrop(J job, double time)
IllegalStateException.rescheduleAfterDrop in class AbstractSimQueue<J extends SimJob,Q extends DELAY>job - The jobs that was dropped.time - The current time (i.e., drop time of the job).IllegalStateException - Always, as a call to this method is unexpected.AbstractSimQueue.drop(J, double),
AbstractSimQueue.removeJobFromQueueUponDrop(J, double)protected final void removeJobFromQueueUponRevokation(J job, double time, boolean auto)
removeJobFromQueueUponRevokation in class AbstractSimQueue<J extends SimJob,Q extends DELAY>job - The job that is to be revoked.time - The current time (i.e., revocation time of the job).auto - Whether or not this applies to an auto-revocation.AbstractSimQueue.cancelDepartureEvent(org.javades.jqueues.r5.entity.jq.SimJQEvent.Departure<J, Q>)protected final void rescheduleAfterRevokation(J job, double time, boolean auto)
rescheduleAfterRevokation in class AbstractSimQueue<J extends SimJob,Q extends DELAY>job - The jobs that was successfully revoked.time - The current time (i.e., revocation time of the job).auto - Whether or not this applies to an auto-revocation.AbstractSimQueue.revoke(double, J, boolean),
AbstractSimQueue.autoRevoke(double, J),
AbstractSimQueue.removeJobFromQueueUponRevokation(J, double, boolean),
SimQueue.AutoRevocationPolicyprotected final void removeJobFromQueueUponDeparture(J departingJob, double time)
removeJobFromQueueUponDeparture in class AbstractSimQueue<J extends SimJob,Q extends DELAY>departingJob - The job that departs.time - The departure (current) time.AbstractSimQueue.depart(double, J),
AbstractSimQueue.rescheduleAfterDeparture(J, double)protected final void rescheduleAfterDeparture(J departedJob, double time)
rescheduleAfterDeparture in class AbstractSimQueue<J extends SimJob,Q extends DELAY>departedJob - The departed job.time - The departure (current) time.AbstractSimQueue.depart(double, J),
AbstractSimQueue.removeJobFromQueueUponDeparture(J, double)Copyright © 2018. All rights reserved.