public static class EncJLExample.TestDelegateSimJob extends AbstractSimJob
AbstractSimEntity.Notifier, AbstractSimEntity.PreNotificationHookSimEntity.Action, SimEntity.UnknownNotificationTypePolicy, SimEntity.UnknownOperationPolicyUSE_ARRAY_OPTIMIZATION| Constructor and Description |
|---|
TestDelegateSimJob(DefaultExampleSimJob realSimJob,
boolean reported) |
| Modifier and Type | Method and Description |
|---|---|
double |
getServiceTime(SimQueue queue)
The requested service time at given queue.
|
getQueue, resetEntitySubClass, setQueueaddPendingNotification, 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, toStringDefault, unregisterSimEntityListener, unregisterStdOutSimEntityListener, updateclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitdoAfterNotifications, doOperation, getEventList, getLastUpdateTime, getRegisteredNotificationTypes, getRegisteredOperations, getSimEntityListeners, getUnknownNotificationTypePolicy, getUnknownOperationPolicy, isIgnoreEventListReset, registerSimEntityListener, resetEntity, setIgnoreEventListReset, setName, setUnknownNotificationTypePolicy, setUnknownOperationPolicy, toStringDefault, unregisterSimEntityListener, updatenotifyEventListResetgetQoS, getQoSClasspublic TestDelegateSimJob(DefaultExampleSimJob realSimJob, boolean reported)
public double getServiceTime(SimQueue queue) throws IllegalArgumentException
SimJob
This method is used by a SimQueue to query the requested service time,
and appropriately schedule a departure event for the job,
but can be called anytime.
The returned value should not change during a visit to a SimQueue,
and it is not manipulated by the queue being visited, in other words,
it cannot be used to query the remaining service time of a job at a queue.
It is safe to change this in-between queue visits. However, the convention is that the method then returns the required service time at the next visit to the queue. For instance, many test and job-factory classes depend on this, as they often directly probe a non-visiting job for its required service time at a queue. Obviously, implementations must be prepared for invocations of this method while not visiting a queue.
getServiceTime in interface SimJobgetServiceTime in class AbstractSimJobqueue - The SimQueue for which the service time is requested,
if null, the service time at the current queue is used,
or zero if the job is not currently visiting a queue.IllegalArgumentException - If the queue supplied cannot serve the job.SimJob.getQueue()Copyright © 2018. All rights reserved.