Class CommonModel

java.lang.Object
common.definitions.CommonModel
All Implemented Interfaces:
CommonConstants, BlockingRegionDefinition, ClassDefinition, SimulationDefinition, StationDefinition, EngineNodeConstants
Direct Known Subclasses:
JSimGraphModel, JSIMModel

Created by IntelliJ IDEA. User: OrsotronIII Date: 24-mag-2005 Time: 9.46.43
  • Field Details

    • incrementalKey

      protected long incrementalKey
    • seed

      protected Long seed
    • useRandomSeed

      protected Boolean useRandomSeed
    • maxDuration

      protected Double maxDuration
    • maxSimulatedTime

      protected Double maxSimulatedTime
    • maxSamples

      protected Integer maxSamples
    • disableStatistic

      protected Boolean disableStatistic
    • maxEvents

      protected Integer maxEvents
    • pollingInterval

      protected Double pollingInterval
    • results

      protected MeasureDefinition results
    • loggerGlbParams

      protected CommonModel.LoggerGlobalParameters loggerGlbParams
    • save

      protected boolean save
    • keyComparator

      protected static Comparator<Object> keyComparator
    • debugLog

      protected static JSimLogger debugLog
    • classesKeyset

      protected Vector<Object> classesKeyset
      search key set of all classes
    • openClassesKeyset

      protected Vector<Object> openClassesKeyset
      search key set of open classes
    • closedClassesKeyset

      protected Vector<Object> closedClassesKeyset
      search key set of closed classes
    • stationsKeyset

      protected Vector<Object> stationsKeyset
      search key set of all stations
    • sourcesKeyset

      protected Vector<Object> sourcesKeyset
      search key set of sources
    • sinksKeyset

      protected Vector<Object> sinksKeyset
      search key set of sinks
    • terminalsKeyset

      protected Vector<Object> terminalsKeyset
      search key set of terminals
    • routersKeyset

      protected Vector<Object> routersKeyset
      search key set of routers
    • delaysKeyset

      protected Vector<Object> delaysKeyset
      search key set of delays
    • serversKeyset

      protected Vector<Object> serversKeyset
      search key set of servers
    • forksKeyset

      protected Vector<Object> forksKeyset
      search key set of forks
    • joinsKeyset

      protected Vector<Object> joinsKeyset
      search key set of joins
    • loggersKeyset

      protected Vector<Object> loggersKeyset
      search key set of loggers
    • classSwitchesKeyset

      protected Vector<Object> classSwitchesKeyset
      search key set of class switches
    • semaphoresKeyset

      protected Vector<Object> semaphoresKeyset
      search key set of semaphores
    • scalersKeyset

      protected Vector<Object> scalersKeyset
      search key set of scalers
    • placesKeyset

      protected Vector<Object> placesKeyset
      search key set of places
    • transitionsKeyset

      protected Vector<Object> transitionsKeyset
      search key set of transitions
    • preloadableKeyset

      protected Vector<Object> preloadableKeyset
      search key set of preloadable stations
    • blockingRegionsKeyset

      protected Vector<Object> blockingRegionsKeyset
      search key set of blocking regions
    • blockableKeyset

      protected Vector<Object> blockableKeyset
      search key set of blockable stations
    • measuresKeyset

      protected Vector<Object> measuresKeyset
      search key set of measures
    • classDataHM

      protected HashMap<Object,Object> classDataHM
      Hashmap for classes parameters
    • stationDataHM

      protected HashMap<Object,Object> stationDataHM
      Hashmap containing station parameters
    • serverTypesHM

      protected HashMap<Object, ServerType> serverTypesHM
      Hashmap containing Server Types
    • serverTypeDistributionsBDM

      protected BDMap serverTypeDistributionsBDM
      BDMap containing service time distributions for each server type and class. on X coordinate must be put class search keys, on Y server type ids.
    • measureDataHM

      protected HashMap<Object, CommonModel.MeasureData> measureDataHM
      Hashmap containing measure parameters
    • blockingDataHM

      protected HashMap<Object,Object> blockingDataHM
      Hashmap containing blocking region parameters
    • connectionsBDM

      protected BDMap connectionsBDM
      BDMap containing station connections. On X coordinate will be put stationKeys for connection targets, on Y for sources.
    • stationDetailsBDM

      protected BDMap stationDetailsBDM
      BDMap containing a set of station details for each station and each class. on X coordinate must be put class search keys, on Y station search keys.
    • blockingDetailsBDM

      protected BDMap blockingDetailsBDM
      BDMap containing a set of blocking region details for each blocking region and each class. on X coordinate must be put class search keys, on Y blocking region search keys.
  • Constructor Details

    • CommonModel

      public CommonModel()
      Creates a new instance of CommonModel
  • Method Details

    • toBeSaved

      public boolean toBeSaved()
      Tells if current model is to be saved
      Returns:
      true if model is to be saved
    • resetSaveState

      public void resetSaveState()
      Resets save state. This MUST be called each time a model is saved
    • getClassKeys

      public Vector<Object> getClassKeys()
      This method returns the key set of all classes.
      Specified by:
      getClassKeys in interface ClassDefinition
    • getOpenClassKeys

      public Vector<Object> getOpenClassKeys()
      This method returns the key set of open classes.
      Specified by:
      getOpenClassKeys in interface ClassDefinition
    • getClosedClassKeys

      public Vector<Object> getClosedClassKeys()
      This method returns the key set of closed classes.
      Specified by:
      getClosedClassKeys in interface ClassDefinition
    • getClassName

      public String getClassName(Object key)
      Returns name of the class, given the search key.
      Specified by:
      getClassName in interface ClassDefinition
    • setClassName

      public void setClassName(Object key, String name)
      Sets name of the class, given the search key.
      Specified by:
      setClassName in interface ClassDefinition
    • getClassType

      public int getClassType(Object key)
      Returns type of the class, given the search key.
      Specified by:
      getClassType in interface ClassDefinition
    • setClassType

      public void setClassType(Object key, int type)
      Sets type of the class, given the search key.
      Specified by:
      setClassType in interface ClassDefinition
    • getClassPriority

      public Integer getClassPriority(Object key)
      Returns priority of the class, given the search key.
      Specified by:
      getClassPriority in interface ClassDefinition
    • setClassPriority

      public void setClassPriority(Object key, Integer priority)
      Sets priority of the class, given the search key.
      Specified by:
      setClassPriority in interface ClassDefinition
    • getClassSoftDeadline

      public Double getClassSoftDeadline(Object key)
      Description copied from interface: ClassDefinition
      Returns soft deadline of the class, given the search key.
      Specified by:
      getClassSoftDeadline in interface ClassDefinition
    • setClassSoftDeadline

      public void setClassSoftDeadline(Object key, Double softDeadline)
      Description copied from interface: ClassDefinition
      Sets soft deadline of the class, given the search key.
      Specified by:
      setClassSoftDeadline in interface ClassDefinition
    • getClassPopulation

      public Integer getClassPopulation(Object key)
      Returns population of the class, given the search key.
      Specified by:
      getClassPopulation in interface ClassDefinition
    • setClassPopulation

      public void setClassPopulation(Object key, Integer population)
      Sets population of the class, given the search key.
      Specified by:
      setClassPopulation in interface ClassDefinition
    • getClassDistribution

      public Object getClassDistribution(Object key)
      Returns inter-arrival time distribution of the class, given the search key.
      Specified by:
      getClassDistribution in interface ClassDefinition
    • setClassDistribution

      public void setClassDistribution(Object key, Object distribution)
      Sets inter-arrival time distribution of the class, given the search key.
      Specified by:
      setClassDistribution in interface ClassDefinition
    • getClassRefStation

      public Object getClassRefStation(Object key)
      Returns reference station of the class, given the search key.
      Specified by:
      getClassRefStation in interface ClassDefinition
    • setClassRefStation

      public void setClassRefStation(Object key, Object refStation)
      Sets reference station of the class, given the search key.
      Specified by:
      setClassRefStation in interface ClassDefinition
    • addClass

      public Object addClass(String name, int type, Integer priority, Double softDeadline, Integer population, Object distribution)
      Adds a new class to the model and sets all class parameters at once.
      Specified by:
      addClass in interface ClassDefinition
      Parameters:
      name - name of the new class.
      type - type of the new class.
      priority - priority of the new class.
      softDeadline - soft deadline of the new class.
      population - population of the new class.
      distribution - inter-arrival time distribution of the new class.
      Returns:
      search key for the new class.
    • deleteClass

      public void deleteClass(Object key)
      Deletes a class from the model, given the search key.
      Specified by:
      deleteClass in interface ClassDefinition
    • getStationKeys

      public Vector<Object> getStationKeys()
      This method returns the key set of all stations.
      Specified by:
      getStationKeys in interface StationDefinition
    • getStationKeysSource

      public Vector<Object> getStationKeysSource()
      This method returns the key set of sources.
      Specified by:
      getStationKeysSource in interface StationDefinition
    • getServerTypeKeys

      public Vector<Object> getServerTypeKeys()
      This method returns the key set of server Types.
      Specified by:
      getServerTypeKeys in interface StationDefinition
    • getStationKeysSink

      public Vector<Object> getStationKeysSink()
      This method returns the key set of sinks.
      Specified by:
      getStationKeysSink in interface StationDefinition
    • getStationKeysTerminal

      public Vector<Object> getStationKeysTerminal()
      This method returns the key set of terminals.
      Specified by:
      getStationKeysTerminal in interface StationDefinition
    • getStationKeysRouter

      public Vector<Object> getStationKeysRouter()
      This method returns the key set of routers.
      Specified by:
      getStationKeysRouter in interface StationDefinition
    • getStationKeysDelay

      public Vector<Object> getStationKeysDelay()
      This method returns the key set of delays.
      Specified by:
      getStationKeysDelay in interface StationDefinition
    • getStationKeysServer

      public Vector<Object> getStationKeysServer()
      This method returns the key set of servers.
      Specified by:
      getStationKeysServer in interface StationDefinition
    • getStationKeysFork

      public Vector<Object> getStationKeysFork()
      This method returns the key set of forks.
      Specified by:
      getStationKeysFork in interface StationDefinition
    • getStationKeysJoin

      public Vector<Object> getStationKeysJoin()
      This method returns the key set of joins.
      Specified by:
      getStationKeysJoin in interface StationDefinition
    • getStationKeysLogger

      public Vector<Object> getStationKeysLogger()
      This method returns the key set of loggers.
      Specified by:
      getStationKeysLogger in interface StationDefinition
    • getStationKeysClassSwitch

      public Vector<Object> getStationKeysClassSwitch()
      This method returns the key set of class switches.
      Specified by:
      getStationKeysClassSwitch in interface StationDefinition
    • getStationKeysSemaphore

      public Vector<Object> getStationKeysSemaphore()
      This method returns the key set of semaphores.
      Specified by:
      getStationKeysSemaphore in interface StationDefinition
    • getStationKeysScaler

      public Vector<Object> getStationKeysScaler()
      This method returns the key set of scalers.
      Specified by:
      getStationKeysScaler in interface StationDefinition
    • getStationKeysPlace

      public Vector<Object> getStationKeysPlace()
      This method returns the key set of places.
      Specified by:
      getStationKeysPlace in interface StationDefinition
    • getStationKeysTransition

      public Vector<Object> getStationKeysTransition()
      This method returns the key set of transitions.
      Specified by:
      getStationKeysTransition in interface StationDefinition
    • getStationKeysPreloadable

      public Vector<Object> getStationKeysPreloadable()
      This method returns the key set of preloadable stations.
      Specified by:
      getStationKeysPreloadable in interface StationDefinition
    • getStationKeysNoSourceSink

      public Vector<Object> getStationKeysNoSourceSink()
      This method returns all station (except sources and sinks) keys.
      Specified by:
      getStationKeysNoSourceSink in interface StationDefinition
    • getStationKeysRefStation

      public Vector<Object> getStationKeysRefStation()
      This method returns reference station keys.
      Specified by:
      getStationKeysRefStation in interface StationDefinition
    • getFJKeys

      public Vector<Object> getFJKeys()
      This method returns fork/join section keys.
      Specified by:
      getFJKeys in interface StationDefinition
    • getFCRegionKeys

      public Vector<Object> getFCRegionKeys()
      This method returns the key set of blocking regions.
      Specified by:
      getFCRegionKeys in interface StationDefinition
    • getStationRegionKeysNoSourceSink

      public Vector<Object> getStationRegionKeysNoSourceSink()
      This method returns all station (except sources and sinks) and blocking region keys.
      Specified by:
      getStationRegionKeysNoSourceSink in interface StationDefinition
    • getStationName

      public String getStationName(Object key)
      Returns name of the station, given the search key.
      Specified by:
      getStationName in interface StationDefinition
    • setStationName

      public void setStationName(Object key, String name)
      Sets name of the station, given the search key.
      Specified by:
      setStationName in interface StationDefinition
    • getStationType

      public String getStationType(Object key)
      Returns type of the station, given the search key.
      Specified by:
      getStationType in interface StationDefinition
    • setStationType

      public void setStationType(Object key, String type)
      Sets type of the station, given the search key.
      Specified by:
      setStationType in interface StationDefinition
    • getStationQueueCapacity

      public Integer getStationQueueCapacity(Object key)
      Returns queue capacity of the station, given the search key.
      Specified by:
      getStationQueueCapacity in interface StationDefinition
    • setStationQueueCapacity

      public void setStationQueueCapacity(Object key, Integer queueCapacity)
      Sets queue capacity of the station, given the search key.
      Specified by:
      setStationQueueCapacity in interface StationDefinition
    • getStationQueueStrategy

      public String getStationQueueStrategy(Object key)
      Returns queue strategy of the station, given the search key.
      Specified by:
      getStationQueueStrategy in interface StationDefinition
    • setStationQueueStrategy

      public void setStationQueueStrategy(Object key, String queueStrategy)
      Sets queue strategy of the station, given the search key.
      Specified by:
      setStationQueueStrategy in interface StationDefinition
    • getStationNumberOfServers

      public Integer getStationNumberOfServers(Object key)
      Returns number of servers of the station, given the search key.
      Specified by:
      getStationNumberOfServers in interface StationDefinition
    • setStationNumberOfServers

      public void setStationNumberOfServers(Object key, Integer numberOfServers)
      Sets number of servers of the station, given the search key.
      Specified by:
      setStationNumberOfServers in interface StationDefinition
    • getStationMaxRunningJobs

      public Integer getStationMaxRunningJobs(Object key)
      Returns max running jobs of the station, given the search key.
      Specified by:
      getStationMaxRunningJobs in interface StationDefinition
    • setStationMaxRunningJobs

      public void setStationMaxRunningJobs(Object key, Integer maxRunningJobs)
      Sets max running jobs of the station, given the search key.
      Specified by:
      setStationMaxRunningJobs in interface StationDefinition
    • setQuantumSize

      public void setQuantumSize(Object key, Double quantaSize)
      Specified by:
      setQuantumSize in interface StationDefinition
    • getQuantumSize

      public Double getQuantumSize(Object key)
      Specified by:
      getQuantumSize in interface StationDefinition
    • setQuantumSwitchoverTime

      public void setQuantumSwitchoverTime(Object key, Double quantumSwitchoverTime)
      Specified by:
      setQuantumSwitchoverTime in interface StationDefinition
    • getQuantumSwitchoverTime

      public Double getQuantumSwitchoverTime(Object key)
      Specified by:
      getQuantumSwitchoverTime in interface StationDefinition
    • getStationTotalCapacity

      public Integer getStationTotalCapacity(Object key)
      Returns total capacity of the station, given the search key.
      Specified by:
      getStationTotalCapacity in interface StationDefinition
    • setStationTotalCapacity

      public void setStationTotalCapacity(Object key, Integer totalStationCapacity)
      Sets total capacity of the station, given the search key.
      Specified by:
      setStationTotalCapacity in interface StationDefinition
    • getStationPollingServerType

      public String getStationPollingServerType(Object key)
      Returns type of polling server, given the search key.
      Specified by:
      getStationPollingServerType in interface StationDefinition
    • setStationPollingServerType

      public void setStationPollingServerType(Object key, String pollingType)
      Sets type of polling server, given the search key.
      Specified by:
      setStationPollingServerType in interface StationDefinition
    • getStationPollingServerKValue

      public Integer getStationPollingServerKValue(Object key)
      Returns k value for K polling servers, given the search key.
      Specified by:
      getStationPollingServerKValue in interface StationDefinition
    • setStationPollingServerKValue

      public void setStationPollingServerKValue(Object key, Integer k)
      Sets k value for K polling servers, given the search key.
      Specified by:
      setStationPollingServerKValue in interface StationDefinition
    • getSwitchoverTimesEnabled

      public Boolean getSwitchoverTimesEnabled(Object key)
      Gets whether setup times are enabled, given the search key.
      Specified by:
      getSwitchoverTimesEnabled in interface StationDefinition
    • setSwitchoverTimesEnabled

      public void setSwitchoverTimesEnabled(Object key, Boolean enabled)
      Sets whether setup times are enabled, given the search key.
      Specified by:
      setSwitchoverTimesEnabled in interface StationDefinition
    • getDelayOffTimesEnabled

      public Boolean getDelayOffTimesEnabled(Object key)
      Gets whether delay off times are enabled, given the search key.
      Specified by:
      getDelayOffTimesEnabled in interface StationDefinition
    • setDelayOffTimesEnabled

      public void setDelayOffTimesEnabled(Object key, Boolean enabled)
      Sets whether delay off times are enabled, given the search key.
      Specified by:
      setDelayOffTimesEnabled in interface StationDefinition
    • getForkBlock

      public Integer getForkBlock(Object key)
      Tells if a fork is blocking
      Author: Bertoli Marco
      Specified by:
      getForkBlock in interface StationDefinition
      Parameters:
      key - : search's key for fork
      Returns:
      maximum number of jobs allowed in the fork-join region (-1 is infinity)
    • setForkBlock

      public void setForkBlock(Object key, Integer value)
      Sets if a fork is blocking
      Author: Bertoli Marco
      Specified by:
      setForkBlock in interface StationDefinition
      Parameters:
      key - : search's key for fork
      value - : maximum number of jobs allowed in the fork-join region (-1 is infinity)
    • getIsSimplifiedFork

      public Boolean getIsSimplifiedFork(Object key)
      Tells if a fork is simplified
      Author: Bertoli Marco
      Specified by:
      getIsSimplifiedFork in interface StationDefinition
      Parameters:
      key - : search's key for fork
      Returns:
      true if the fork is simplified, false otherwise
    • setIsSimplifiedFork

      public void setIsSimplifiedFork(Object key, Boolean value)
      Sets if a fork is simplified
      Author: Bertoli Marco
      Specified by:
      setIsSimplifiedFork in interface StationDefinition
      Parameters:
      key - : search's key for fork
      value - : true if the fork is simplified, false otherwise
    • addStation

      public Object addStation(String name, String type, int nextServerNum, List<ServerType> servers)
      Adds a new station to the model, given the station name and type.
      Specified by:
      addStation in interface StationDefinition
      Parameters:
      name - name of the new station.
      type - type of the new station.
      Returns:
      search key for the new station.
    • deleteStation

      public void deleteStation(Object key)
      Deletes a station from the model, given the search key.
      Specified by:
      deleteStation in interface StationDefinition
    • getClassStationSoftDeadline

      public Double getClassStationSoftDeadline(Object stationKey, Object classKey)
      Specified by:
      getClassStationSoftDeadline in interface StationDefinition
    • setClassStationSoftDeadline

      public void setClassStationSoftDeadline(Object stationKey, Object classKey, Double softDeadline)
      Specified by:
      setClassStationSoftDeadline in interface StationDefinition
    • getQueueCapacity

      public Integer getQueueCapacity(Object stationKey, Object classKey)
      Returns queue capacity for a station and a class, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getQueueCapacity in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      integer for queue capacity.
    • setQueueCapacity

      public void setQueueCapacity(Object stationKey, Object classKey, Integer queueCapacity)
      Sets queue capacity for a station and a class, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setQueueCapacity in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      queueCapacity - integer for queue capacity.
    • getQueueStrategy

      public String getQueueStrategy(Object stationKey, Object classKey)
      Returns queue strategy for a station and a class, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getQueueStrategy in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      string name for queue strategy.
    • setQueueStrategy

      public void setQueueStrategy(Object stationKey, Object classKey, String queueStrategy)
      Sets queue strategy for a station and a class, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setQueueStrategy in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      queueStrategy - : string name for queue strategy.
    • getDropRule

      public String getDropRule(Object stationKey, Object classKey)
      Returns drop rule associated with given station queue section if capacity is finite.
      Specified by:
      getDropRule in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      FINITE_DROP || FINITE_BLOCK || FINITE_WAITING || FINITE_RETRIAL
    • setDropRule

      public void setDropRule(Object stationKey, Object classKey, String dropRule)
      Sets drop rule associated with given station queue section if capacity is finite.
      Specified by:
      setDropRule in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      dropRule - : FINITE_DROP || FINITE_BLOCK || FINITE_WAITING || FINITE_RETRIAL
    • getImpatienceType

      public ImpatienceType getImpatienceType(Object stationKey, Object classKey)
      Returns impatience type associated with given station queue section.
      Specified by:
      getImpatienceType in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      NONE || BALKING || RENEGING
    • setImpatienceType

      public void setImpatienceType(Object stationKey, Object classKey, ImpatienceType impatienceType)
      Sets impatience type associated with given station queue section.
      Specified by:
      setImpatienceType in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      impatienceType - NONE || BALKING || RENEGING
    • getImpatienceParameter

      public ImpatienceParameter getImpatienceParameter(Object stationKey, Object classKey)
      Returns impatience parameter associated with given station queue section.
      Specified by:
      getImpatienceParameter in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      impatience parameter for station and class.
    • setImpatienceParameter

      public void setImpatienceParameter(Object stationKey, Object classKey, ImpatienceParameter impatienceParameter)
      Sets impatience parameter associated with given station queue section.
      Specified by:
      setImpatienceParameter in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      impatienceParameter - parameter for station and class.
    • resetImpatience

      public void resetImpatience(Object stationKey, Object classKey)
      Resets impatience strategy associated with given station queue section.
      Specified by:
      resetImpatience in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
    • updateBalkingParameter

      public void updateBalkingParameter(Object stationKey, Object classKey, String serverStationQueuePolicy)
      Updates balking parameter associated with given station queue section.
      Specified by:
      updateBalkingParameter in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      serverStationQueuePolicy - : queue policy for station.
    • getRetrialDistribution

      public Object getRetrialDistribution(Object stationKey, Object classKey)
      Returns retrial rate distribution for class and station, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getRetrialDistribution in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      distribution for specified class and station.
    • setRetrialDistribution

      public void setRetrialDistribution(Object stationKey, Object classKey, Object distribution)
      Sets retrial rate distribution for class and station, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setRetrialDistribution in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      distribution - : distribution to be set for specified class and station.
    • getServiceWeight

      public Double getServiceWeight(Object stationKey, Object classKey)
      Returns service weight for class and station, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getServiceWeight in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      weight for specified class and station.
    • setServiceWeight

      public void setServiceWeight(Object stationKey, Object classKey, Double weight)
      Sets service weight for class and station, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setServiceWeight in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      weight - : weight to be set for specified class and station.
    • getServiceTimeDistribution

      public Object getServiceTimeDistribution(Object stationKey, Object classKey)
      Returns service time distribution for class and station, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getServiceTimeDistribution in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      distribution for specified class and station.
    • getServiceTimeDistribution

      public Object getServiceTimeDistribution(Object stationKey, Object classKey, Object serverTypeKey)
      Returns service time distribution for class, station and server type, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getServiceTimeDistribution in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      serverTypeKey - : search key for server type.
      Returns:
      distribution for specified class and station.
    • setServiceTimeDistribution

      public void setServiceTimeDistribution(Object stationKey, Object classKey, Object distribution)
      Sets service time distribution for class and station, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setServiceTimeDistribution in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      distribution - : distribution to be set for specified class and station.
    • setServiceTimeDistribution

      public void setServiceTimeDistribution(Object stationKey, Object classKey, Object serverTypeKey, Object distribution)
      Sets service time distribution for class, station and server type, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setServiceTimeDistribution in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      serverTypeKey - : search key for server type.
      distribution - : distribution to be set for specified class and station.
    • getPollingSwitchoverDistribution

      public Object getPollingSwitchoverDistribution(Object stationKey, Object classKey)
      Returns switchover period distribution for class and station, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getPollingSwitchoverDistribution in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      distribution for specified class and station.
    • setPollingSwitchoverDistribution

      public void setPollingSwitchoverDistribution(Object stationKey, Object classKey, Object distribution)
      Sets switchover period distribution for class and station, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setPollingSwitchoverDistribution in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      distribution - : distribution to be set for specified class and station.
    • getSwitchoverTimeDistribution

      public Object getSwitchoverTimeDistribution(Object stationKey, Object fromClassKey, Object toClassKey)
      Returns setup time distribution for class and station, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getSwitchoverTimeDistribution in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      fromClassKey - : search key for current class.
      toClassKey - : search key for next class.
      Returns:
      distribution for the specified class and station.
    • setSwitchoverTimeDistribution

      public void setSwitchoverTimeDistribution(Object stationKey, Object fromClassKey, Object toClassKey, Object distribution)
      Sets setup time distribution for class and station, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setSwitchoverTimeDistribution in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      fromClassKey - : search key for current class.
      toClassKey - : search key for next class.
      distribution - : distribution to be set for specified class and station.
    • getDelayOffTimeDistribution

      public Object getDelayOffTimeDistribution(Object stationKey, Object classKey)
      Specified by:
      getDelayOffTimeDistribution in interface StationDefinition
    • setDelayOffTimeDistribution

      public void setDelayOffTimeDistribution(Object stationKey, Object classKey, Object distribution)
      Specified by:
      setDelayOffTimeDistribution in interface StationDefinition
    • getSetupTimeDistribution

      public Object getSetupTimeDistribution(Object stationKey, Object classKey)
      Specified by:
      getSetupTimeDistribution in interface StationDefinition
    • setSetupTimeDistribution

      public void setSetupTimeDistribution(Object stationKey, Object classKey, Object distribution)
      Specified by:
      setSetupTimeDistribution in interface StationDefinition
    • getServerNumRequired

      public Integer getServerNumRequired(Object stationKey, Object classKey)
      Returns number of servers required for a specific class, given the search key. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getServerNumRequired in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      num for specified class and station.
    • setServerNumRequired

      public void setServerNumRequired(Object stationKey, Object classKey, Integer num)
      Sets number of servers of the station, given the search key.
      Specified by:
      setServerNumRequired in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      num - : server number required to be set for specified class and station.
    • getRoutingStrategy

      public Object getRoutingStrategy(Object stationKey, Object classKey)
      Returns routing strategy for class and station, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getRoutingStrategy in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      routing strategy for specified class and station.
    • setRoutingStrategy

      public void setRoutingStrategy(Object stationKey, Object classKey, Object routingStrategy)
      Sets routing strategy for class and station, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setRoutingStrategy in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      routingStrategy - : routing strategy to be set for specified class and station.
    • getForkStrategy

      public Object getForkStrategy(Object stationKey, Object classKey)
      Returns fork strategy for class and station, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getForkStrategy in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      fork strategy for specified class and station.
    • setForkStrategy

      public void setForkStrategy(Object stationKey, Object classKey, Object forkStrategy)
      Sets fork strategy for class and station, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setForkStrategy in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      forkStrategy - : fork strategy to be set for specified class and station.
    • getJoinStrategy

      public Object getJoinStrategy(Object stationKey, Object classKey)
      Returns join strategy for class and station, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getJoinStrategy in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      join strategy for specified class and station.
    • setJoinStrategy

      public void setJoinStrategy(Object stationKey, Object classKey, Object joinStrategy)
      Sets join strategy for class and station, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setJoinStrategy in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      joinStrategy - : join strategy to be set for specified class and station.
    • getSemaphoreStrategy

      public Object getSemaphoreStrategy(Object stationKey, Object classKey)
      Returns semaphore strategy for class and station, given their search keys. If specified station cannot accept this kind of parameter, null value is returned.
      Specified by:
      getSemaphoreStrategy in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      Returns:
      semaphore strategy for specified class and station.
    • setSemaphoreStrategy

      public void setSemaphoreStrategy(Object stationKey, Object classKey, Object semaphoreStrategy)
      Sets semaphore strategy for class and station, given their search keys. If specified station cannot accept this kind of parameter, no value will be set.
      Specified by:
      setSemaphoreStrategy in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      classKey - : search key for class.
      semaphoreStrategy - : semaphore strategy to be set for specified class and station.
    • getLoggingParameters

      public LoggerParameters getLoggingParameters(Object stationKey)
      Returns logging parameters for the logger. MF'08 0.7.4
      Specified by:
      getLoggingParameters in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
    • setLoggingParameters

      public void setLoggingParameters(Object stationKey, LoggerParameters loggerParameters)
      Sets logging parameters for the logger. MF'08 0.7.4
      Specified by:
      setLoggingParameters in interface StationDefinition
      Parameters:
      stationKey - : search key for station.
      loggerParameters - : local LoggerParameters.
    • getLoggingGlbParameter

      public String getLoggingGlbParameter(String selector)
      Returns logging parameters for the Global logfile. MF'08 0.7.4
      Specified by:
      getLoggingGlbParameter in interface StationDefinition
      Parameters:
      selector - : either "path", "delim", or "autoAppend"
    • setLoggingGlbParameter

      public void setLoggingGlbParameter(String selector, String value)
      Sets logging parameters for the Global logfile. MF'08 0.7.4
      Specified by:
      setLoggingGlbParameter in interface StationDefinition
      Parameters:
      selector - : either "path", "delim", "decimalSeparator", or "autoAppend"
      value - : String to assign to variable named by selector.
    • manageProbabilities

      public void manageProbabilities()
      Manages the routing, fork and class switch probabilities.
      Specified by:
      manageProbabilities in interface StationDefinition
    • normalizeRoutingProbabilities

      public void normalizeRoutingProbabilities(Object stationKey, Object classKey, Map<Object,Double> values)
      Normalizes the routing probabilities.
      Specified by:
      normalizeRoutingProbabilities in interface StationDefinition
    • normalizeForkProbabilities

      public void normalizeForkProbabilities(Map<Object,Double> values)
      Normalizes the fork probabilities.
      Specified by:
      normalizeForkProbabilities in interface StationDefinition
    • normalizeClassSwitchProbabilities

      public void normalizeClassSwitchProbabilities(Object classKey, Map values, Number example)
      Normalizes the class switch probabilities.
      Specified by:
      normalizeClassSwitchProbabilities in interface StationDefinition
    • addStationDetails

      protected void addStationDetails(Object key)
      Adds station details, given the search key.
    • deleteStationDetails

      protected void deleteStationDetails(Object key)
      Deletes station details, given the search key.
    • addStationDetailsForClass

      protected void addStationDetailsForClass(Object key)
      Adds station details for a class, given the search key.
    • deleteStationDetailsForClass

      protected void deleteStationDetailsForClass(Object key)
      Deletes station details for a class, given the search key.
    • setConnected

      public boolean setConnected(Object sourceKey, Object targetKey, boolean areConnected)
      Adds a connection between two stations in this model, given search keys of source and target stations.
      Specified by:
      setConnected in interface StationDefinition
      Parameters:
      sourceKey - : search key for source station
      targetKey - : search key for target station
      areConnected - : true if stations must be connected, false otherwise.
      Returns:
      : true if connection status was changed, false otherwise.
    • areConnected

      public boolean areConnected(Object sourceKey, Object targetKey)
      Tells whether two stations are connected
      Specified by:
      areConnected in interface StationDefinition
      Parameters:
      sourceKey - : search key for source station
      targetKey - : search key for target station
      Returns:
      : true if stations are connected, false otherwise.
    • areConnectable

      public boolean areConnectable(Object sourceKey, Object targetKey)
      Tells whether two stations can be connected
      Specified by:
      areConnectable in interface StationDefinition
      Parameters:
      sourceKey - : search key for source station
      targetKey - : search key for target station
      Returns:
      : true if stations are connectable, false otherwise.
    • getForwardConnections

      public Vector<Object> getForwardConnections(Object stationKey)
      Returns a set of station keys specified station is connected to as a source.
      Specified by:
      getForwardConnections in interface StationDefinition
      Parameters:
      stationKey - : source station for which (target) connected stations must be returned.
      Returns:
      Vector containing keys for connected stations.
    • getBackwardConnections

      public Vector<Object> getBackwardConnections(Object stationKey)
      Returns a set of station keys specified station is connected to as a target.
      Specified by:
      getBackwardConnections in interface StationDefinition
      Parameters:
      stationKey - : source station for which (source) connected stations must be returned.
      Returns:
      Vector containing keys for connected stations.
    • getBackwardConnectedPlaces

      public Vector<Object> getBackwardConnectedPlaces(Object stationKey)
      Specified by:
      getBackwardConnectedPlaces in interface StationDefinition
      Parameters:
      stationKey - : source station which connected places must be returned
      Returns:
      Vector containing backward connected places
    • canBeConnected

      protected boolean canBeConnected(Object sourceKey, Object targetKey)
      Tells whether two stations can be connected. Subclasses can override this method to change behaviour in connection creation.
    • addMeasure

      public Object addMeasure(String type, Object stationKey, Object classKey)
      Description copied from interface: SimulationDefinition
      Adds a new measure for specified class and station (or region)
      Specified by:
      addMeasure in interface SimulationDefinition
      Parameters:
      type - : code for measure type.
      stationKey - : specified station (or region) for measure
      classKey - : specified class
      Returns:
      search key for new measure
    • addMeasure

      public Object addMeasure(String type, Object stationKey, Object classKey, Double alpha, Double precision, boolean log)
      Description copied from interface: SimulationDefinition
      Adds a new measure for specified class and station (or region)
      Specified by:
      addMeasure in interface SimulationDefinition
      Parameters:
      type - : code for measure type.
      stationKey - : specified station for measure
      classKey - : specified class
      alpha - : alpha parameter for this measure
      precision - : precision parameter for this measure
      log - : true to log the measure to CSV. False to avoid it.
      Returns:
      search key for new measure
    • removeMeasure

      public void removeMeasure(Object measureKey)
      Description copied from interface: SimulationDefinition
      Removes a measure from list, given its search key
      Specified by:
      removeMeasure in interface SimulationDefinition
      Parameters:
      measureKey - : search Key for measure to be removed
    • getMeasureKeys

      public Vector<Object> getMeasureKeys()
      Description copied from interface: SimulationDefinition
      Returns list of measure search keys
      Specified by:
      getMeasureKeys in interface SimulationDefinition
      Returns:
      Vector containing all of the measure search keys
    • getMeasureType

      public String getMeasureType(Object measureKey)
      Description copied from interface: SimulationDefinition
      Returns type of measure, given measure search key
      Specified by:
      getMeasureType in interface SimulationDefinition
      Parameters:
      measureKey - : search key
      Returns:
      measure type
    • setMeasureType

      public void setMeasureType(String newType, Object measureKey)
      Description copied from interface: SimulationDefinition
      Sets type of parameter to be measured
      Specified by:
      setMeasureType in interface SimulationDefinition
      Parameters:
      newType - new type for this measure
      measureKey - search key for this measure
    • getMeasureStation

      public Object getMeasureStation(Object measureKey)
      Description copied from interface: SimulationDefinition
      Returns search key for station a certain measure refers to.
      Specified by:
      getMeasureStation in interface SimulationDefinition
      Parameters:
      measureKey - search key for measure
      Returns:
      search key for station.
    • setMeasureStation

      public void setMeasureStation(Object stationKey, Object measureKey)
      Description copied from interface: SimulationDefinition
      Changes reference station for specified measure, given its search key
      Specified by:
      setMeasureStation in interface SimulationDefinition
      Parameters:
      stationKey - : search key for station this measure must be referred to.
      measureKey - : search key for measure.
    • getMeasureClass

      public Object getMeasureClass(Object measureKey)
      Description copied from interface: SimulationDefinition
      Returns search key for class this measure refers to.
      Specified by:
      getMeasureClass in interface SimulationDefinition
      Parameters:
      measureKey - search key for measure
      Returns:
      search key for class
    • setMeasureClass

      public void setMeasureClass(Object classKey, Object measureKey)
      Description copied from interface: SimulationDefinition
      Changes reference class for specified measure, given its search key
      Specified by:
      setMeasureClass in interface SimulationDefinition
      Parameters:
      classKey - new class search key
      measureKey - measure search key
    • getMeasureServerTypeKey

      public Object getMeasureServerTypeKey(Object measureKey)
      Description copied from interface: SimulationDefinition
      Returns search key for server type this measure refers to.
      Specified by:
      getMeasureServerTypeKey in interface SimulationDefinition
      Parameters:
      measureKey - search key for measure
      Returns:
      server type key for class
    • setMeasureServerTypeKey

      public void setMeasureServerTypeKey(Object serverTypeKey, Object measureKey)
      Description copied from interface: SimulationDefinition
      Changes server type for specified measure, given its search key
      Specified by:
      setMeasureServerTypeKey in interface SimulationDefinition
      Parameters:
      serverTypeKey - new server type key
      measureKey - measure search key
    • getMeasureAlpha

      public Double getMeasureAlpha(Object measureKey)
      Description copied from interface: SimulationDefinition
      Returns value for alpha parameter of a specific measure, given its search key.
      Specified by:
      getMeasureAlpha in interface SimulationDefinition
      Parameters:
      measureKey - search key for station
      Returns:
      value of alpha parameter
    • setMeasureAlpha

      public void setMeasureAlpha(Double alpha, Object measureKey)
      Description copied from interface: SimulationDefinition
      Sets value for alpha parameter of a specific measure, given its search key.
      Specified by:
      setMeasureAlpha in interface SimulationDefinition
      Parameters:
      alpha - value of alpha parameter
      measureKey - search key for station
    • getMeasurePrecision

      public Double getMeasurePrecision(Object measureKey)
      Description copied from interface: SimulationDefinition
      Returns value for precision parameter of a specific measure, given its search key.
      Specified by:
      getMeasurePrecision in interface SimulationDefinition
      Parameters:
      measureKey - search key for station
      Returns:
      value of precision parameter
    • setMeasurePrecision

      public void setMeasurePrecision(Double precision, Object measureKey)
      Description copied from interface: SimulationDefinition
      Sets value for alpha parameter of a specific measure, given its search key.
      Specified by:
      setMeasurePrecision in interface SimulationDefinition
      Parameters:
      precision - value of alpha parameter
      measureKey - search key for station
    • getMeasureLog

      public boolean getMeasureLog(Object measureKey)
      Description copied from interface: SimulationDefinition
      Tells if a measure should be logged
      Specified by:
      getMeasureLog in interface SimulationDefinition
      Parameters:
      measureKey - the key of the measure
      Returns:
      true if measure should be logged, false otherwise.
    • setMeasureLog

      public void setMeasureLog(boolean log, Object measureKey)
      Description copied from interface: SimulationDefinition
      Sets if measure should be logged
      Specified by:
      setMeasureLog in interface SimulationDefinition
      Parameters:
      log - true to log measure, false to avoid (default)
      measureKey - the key of the measure
    • isGlobalMeasure

      public boolean isGlobalMeasure(String type)
      Tells if a given measure is global
      Specified by:
      isGlobalMeasure in interface SimulationDefinition
      Parameters:
      type - type of given measure
      Returns:
      true if measure is global
    • isSinkMeasure

      public boolean isSinkMeasure(String type)
      Tells if a given measure is for sinks only
      Specified by:
      isSinkMeasure in interface SimulationDefinition
      Parameters:
      type - type of given measure
      Returns:
      true if measure is for sinks only
    • isFCRMeasure

      public boolean isFCRMeasure(String type)
      Tells if a given measure is for blocking regions only
      Specified by:
      isFCRMeasure in interface SimulationDefinition
      Parameters:
      type - type of given measure
      Returns:
      true if measure is for blocking regions only
    • isFJMeasure

      public boolean isFJMeasure(String type)
      Tells if a given measure is for fork/join sections only
      Specified by:
      isFJMeasure in interface SimulationDefinition
      Parameters:
      type - type of given measure
      Returns:
      true if measure is for fork/join sections only
    • getPreloadedJobs

      public Integer getPreloadedJobs(Object stationKey, Object classKey)
      Returns number of preloaded jobs at specified station for specified class.
      Specified by:
      getPreloadedJobs in interface SimulationDefinition
      Parameters:
      stationKey - station at which preloaded jobs are preloaded.
      classKey - class to which preloaded jobs belong.
      Returns:
      number of preloaded jobs.
    • setPreloadedJobs

      public void setPreloadedJobs(Object stationKey, Object classKey, Integer preload)
      Sets number of preloaded jobs at specified station for specified class. For closed classes, total number of preloaded jobs for a class over all stations must be equal to class population, otherwise update is canceled.
      Specified by:
      setPreloadedJobs in interface SimulationDefinition
      Parameters:
      stationKey - station at which preloaded jobs are preloaded.
      classKey - class to which preloaded jobs belong.
      preload - number of preloaded jobs.
    • getPreloadedJobsNumber

      public Integer getPreloadedJobsNumber(Object classKey)
      Returns total number of preloaded jobs for specified class.
      Specified by:
      getPreloadedJobsNumber in interface SimulationDefinition
      Parameters:
      classKey - class to which preloaded jobs belong.
      Returns:
      total number of preloaded jobs.
    • manageJobs

      public void manageJobs()
      This method is used to manage number of jobs for every class. If class is closed all spare jobs will be allocated to its reference source, if for some reasons more jobs are allocated than max population, they are reduced. Uses this method only when strictly necessary as it can be slow if the model is big.
      Specified by:
      manageJobs in interface SimulationDefinition
    • isStationTypePreloadable

      protected boolean isStationTypePreloadable(String stationType)
      Tells if a given station type is preloadable
      Parameters:
      stationType - type of station
      Returns:
      true if station of that type is preloadable, false otherwise
    • getSimulationSeed

      public Long getSimulationSeed()
      Gets seed for simulation.
      Specified by:
      getSimulationSeed in interface SimulationDefinition
      Returns:
      seed for simulation.
    • setSimulationSeed

      public void setSimulationSeed(Long seed)
      Sets seed for simulation.
      Specified by:
      setSimulationSeed in interface SimulationDefinition
      Parameters:
      seed - seed for simulation.
    • getUseRandomSeed

      public Boolean getUseRandomSeed()
      Tells if random seed is used.
      Specified by:
      getUseRandomSeed in interface SimulationDefinition
      Returns:
      true if random seed is used, false otherwise.
    • setUseRandomSeed

      public void setUseRandomSeed(Boolean useRandomSeed)
      Sets if random seed is used.
      Specified by:
      setUseRandomSeed in interface SimulationDefinition
      Parameters:
      useRandomSeed - true if random seed is used, false otherwise.
    • getMaximumDuration

      public Double getMaximumDuration()
      Returns maximum duration for simulation in seconds.
      Specified by:
      getMaximumDuration in interface SimulationDefinition
      Returns:
      seconds of maximum duration for simulation.
    • setMaximumDuration

      public void setMaximumDuration(Double durationSeconds)
      Sets maximum duration for simulation in seconds.
      Specified by:
      setMaximumDuration in interface SimulationDefinition
      Parameters:
      durationSeconds - seconds of maximum duration for simulation.
    • getMaxSimulatedTime

      public Double getMaxSimulatedTime()
      Returns maximum duration for simulation in time units.
      Specified by:
      getMaxSimulatedTime in interface SimulationDefinition
      Returns:
      time units of maximum duration for simulation.
    • setMaxSimulatedTime

      public void setMaxSimulatedTime(Double duration)
      Sets maximum duration for simulation in time units.
      Specified by:
      setMaxSimulatedTime in interface SimulationDefinition
      Parameters:
      duration - time units of maximum duration for simulation.
    • getMaxSimulationSamples

      public Integer getMaxSimulationSamples()
      Returns maximum number of simulation samples.
      Specified by:
      getMaxSimulationSamples in interface SimulationDefinition
      Returns:
      maximum number of simulation samples.
    • setMaxSimulationSamples

      public void setMaxSimulationSamples(Integer maxSamples)
      Sets maximum number of simulation samples.
      Specified by:
      setMaxSimulationSamples in interface SimulationDefinition
      Parameters:
      maxSamples - maximum number of simulation samples.
    • getDisableStatistic

      public Boolean getDisableStatistic()
      Tells if statistic check is disabled.
      Specified by:
      getDisableStatistic in interface SimulationDefinition
      Returns:
      true if statistic check is disabled, false otherwise.
    • setDisableStatistic

      public void setDisableStatistic(Boolean disableStatistic)
      Sets if statistic check is disabled.
      Specified by:
      setDisableStatistic in interface SimulationDefinition
      Parameters:
      disableStatistic - true if statistic check is disabled, false otherwise.
    • getMaxSimulationEvents

      public Integer getMaxSimulationEvents()
      Returns maximum number of simulation events.
      Specified by:
      getMaxSimulationEvents in interface SimulationDefinition
      Returns:
      maximum number of simulation events.
    • setMaxSimulationEvents

      public void setMaxSimulationEvents(Integer maxEvents)
      Sets maximum number of simulation events.
      Specified by:
      setMaxSimulationEvents in interface SimulationDefinition
      Parameters:
      maxEvents - maximum number of simulation events.
    • getPollingInterval

      public Double getPollingInterval()
      Returns polling interval for temporary measures.
      Specified by:
      getPollingInterval in interface SimulationDefinition
      Returns:
      polling interval for temporary measures.
    • setPollingInterval

      public void setPollingInterval(Double pollingInterval)
      Sets polling interval for temporary measures.
      Specified by:
      setPollingInterval in interface SimulationDefinition
      Parameters:
      pollingInterval - polling interval for temporary measures.
    • getSimulationResults

      public MeasureDefinition getSimulationResults()
      Returns last simulation results
      Specified by:
      getSimulationResults in interface SimulationDefinition
      Returns:
      simulation results or null if no simulation was performed
    • setSimulationResults

      public void setSimulationResults(MeasureDefinition results)
      Sets simulation results
      Specified by:
      setSimulationResults in interface SimulationDefinition
      Parameters:
      results - simulation results data structure
    • containsSimulationResults

      public boolean containsSimulationResults()
      Tells if current model contains simulation results
      Specified by:
      containsSimulationResults in interface SimulationDefinition
      Returns:
      true if getSimulationResults() returns a non-null object
    • isAnimationEnabled

      public boolean isAnimationEnabled()
      Tells if queue animation is enabled
      Specified by:
      isAnimationEnabled in interface SimulationDefinition
      Returns:
      true if the animation is enabled
    • setAnimationEnabled

      public void setAnimationEnabled(boolean enabled)
      Enable / disable queue animation
      Specified by:
      setAnimationEnabled in interface SimulationDefinition
      Parameters:
      enabled - - set it to true to enable queue animation
    • isParametricAnalysisEnabled

      public boolean isParametricAnalysisEnabled()
      Tells if parametric analysis is enabled
      Specified by:
      isParametricAnalysisEnabled in interface SimulationDefinition
      Returns:
      true if parametric analysis is enabled
    • setParametricAnalysisEnabled

      public void setParametricAnalysisEnabled(boolean enabled)
      Enable / disable parametric analysis
      Specified by:
      setParametricAnalysisEnabled in interface SimulationDefinition
      Parameters:
      enabled - - set it to true to enable parametric analysis
    • getParametricAnalysisModel

      public ParametricAnalysisDefinition getParametricAnalysisModel()
      Returns the ParametricAnalysisModel
      Specified by:
      getParametricAnalysisModel in interface SimulationDefinition
      Returns:
      the parametricAnalysisModel
    • setParametricAnalysisModel

      public void setParametricAnalysisModel(ParametricAnalysisDefinition pad)
      Sets the ParametricAnalysisModel
      Specified by:
      setParametricAnalysisModel in interface SimulationDefinition
      Parameters:
      pad - the parametricAnalysisModel to be set
    • setSaveChanged

      public void setSaveChanged()
      Tells model that some data has been changed and need to be saved. This is used by Parametric Analysis
      Specified by:
      setSaveChanged in interface SimulationDefinition
    • getClassByName

      public Object getClassByName(String className)
      Returns the search key for the class, given the class name.
      Specified by:
      getClassByName in interface ClassDefinition
    • getStationByName

      public Object getStationByName(String stationName)
      Returns the search key for the station, given the station name.
      Specified by:
      getStationByName in interface StationDefinition
    • addBlockingRegion

      public Object addBlockingRegion(String name, String type)
      Adds a new blocking region to the model
      Specified by:
      addBlockingRegion in interface BlockingRegionDefinition
      Parameters:
      name - name of the new region
      type - type of the new region
      Returns:
      search's key for new region
    • deleteBlockingRegion

      public void deleteBlockingRegion(Object key)
      Deletes a blocking region from the model
      Specified by:
      deleteBlockingRegion in interface BlockingRegionDefinition
      Parameters:
      key - search's key for region
    • getRegionKeys

      public Vector<Object> getRegionKeys()
      Returns the entire set of blocking region keys
      Specified by:
      getRegionKeys in interface BlockingRegionDefinition
      Returns:
      the entire set of blocking region keys
    • getRegionName

      public String getRegionName(Object regionKey)
      Gets the name of a blocking region
      Specified by:
      getRegionName in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      Returns:
      name of the region
    • setRegionName

      public void setRegionName(Object regionKey, String name)
      Sets the name of a blocking region
      Specified by:
      setRegionName in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      name - name of the region
    • getRegionType

      public String getRegionType(Object regionKey)
      Gets the type of a blocking region
      Specified by:
      getRegionType in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      Returns:
      type of the region
    • setRegionType

      public void setRegionType(Object regionKey, String type)
      Sets the type of a blocking region
      Specified by:
      setRegionType in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      type - type of the region
    • getRegionCustomerConstraint

      public Integer getRegionCustomerConstraint(Object regionKey)
      Gets the global customer number constraint for a blocking region
      Specified by:
      getRegionCustomerConstraint in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      Returns:
      maximum number of allowed customers (-1 means infinity)
    • setRegionCustomerConstraint

      public void setRegionCustomerConstraint(Object regionKey, Integer maxJobs)
      Sets the global customer number constraint for a blocking region
      Specified by:
      setRegionCustomerConstraint in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      maxJobs - maximum number of allowed customers (-1 means infinity)
    • getRegionMemorySize

      public Integer getRegionMemorySize(Object regionKey)
      Gets the global memory size constraint for a blocking region
      Specified by:
      getRegionMemorySize in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      Returns:
      maximum size of allowed memory (-1 means infinity)
    • setRegionMemorySize

      public void setRegionMemorySize(Object regionKey, Integer maxMemory)
      Sets the global memory size constraint for a blocking region
      Specified by:
      setRegionMemorySize in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      maxMemory - maximum size of allowed memory (-1 means infinity)
    • getRegionClassCustomerConstraint

      public Integer getRegionClassCustomerConstraint(Object regionKey, Object classKey)
      Gets the customer number constraint for a blocking region and a class
      Specified by:
      getRegionClassCustomerConstraint in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      Returns:
      maximum number of allowed customers for specified class (-1 means infinity)
    • setRegionClassCustomerConstraint

      public void setRegionClassCustomerConstraint(Object regionKey, Object classKey, Integer maxJobs)
      Sets the customer number constraint for a blocking region and a class
      Specified by:
      setRegionClassCustomerConstraint in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      maxJobs - maximum number of allowed customers for specified class (-1 means infinity)
    • getRegionClassMemorySize

      public Integer getRegionClassMemorySize(Object regionKey, Object classKey)
      Gets the memory size constraint for a blocking region and a class
      Specified by:
      getRegionClassMemorySize in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      Returns:
      maximum size of allowed memory for specified class (-1 means infinity)
    • setRegionClassMemorySize

      public void setRegionClassMemorySize(Object regionKey, Object classKey, Integer maxMemory)
      Sets the memory size constraint for a blocking region and a class
      Specified by:
      setRegionClassMemorySize in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      maxMemory - maximum size of allowed memory for specified class (-1 means infinity)
    • getRegionClassDropRule

      public Boolean getRegionClassDropRule(Object regionKey, Object classKey)
      Gets the drop rule for a blocking region and a class
      Specified by:
      getRegionClassDropRule in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      Returns:
      true if jobs of specified class can be dropped, false otherwise
    • setRegionClassDropRule

      public void setRegionClassDropRule(Object regionKey, Object classKey, Boolean drop)
      Sets the drop rule for a blocking region and a class
      Specified by:
      setRegionClassDropRule in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      drop - true if jobs of specified class can be dropped, false otherwise
    • getRegionClassWeight

      public Integer getRegionClassWeight(Object regionKey, Object classKey)
      Gets the weight of each job for a blocking region and a class
      Specified by:
      getRegionClassWeight in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      Returns:
      weight of each job for specified class
    • setRegionClassWeight

      public void setRegionClassWeight(Object regionKey, Object classKey, Integer weight)
      Sets the weight of each job for a blocking region and a class
      Specified by:
      setRegionClassWeight in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      weight - weight of each job for specified class
    • getRegionClassSize

      public Integer getRegionClassSize(Object regionKey, Object classKey)
      Gets the size of each job for a blocking region and a class
      Specified by:
      getRegionClassSize in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      Returns:
      size of each job for specified class
    • setRegionClassSize

      public void setRegionClassSize(Object regionKey, Object classKey, Integer size)
      Sets the size of each job for a blocking region and a class
      Specified by:
      setRegionClassSize in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      size - size of each job for specified class
    • getRegionClassSoftDeadline

      public Double getRegionClassSoftDeadline(Object regionKey, Object classKey)
      Description copied from interface: BlockingRegionDefinition
      Gets the soft deadline of each job for a blocking region and a class
      Specified by:
      getRegionClassSoftDeadline in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      Returns:
      soft deadline of each job for specified class
    • setRegionClassSoftDeadline

      public void setRegionClassSoftDeadline(Object regionKey, Object classKey, Double softDeadline)
      Description copied from interface: BlockingRegionDefinition
      Sets the soft deadline of each job for a blocking region and a class
      Specified by:
      setRegionClassSoftDeadline in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      classKey - search's key for class
      softDeadline - soft deadline of each job for specified class
    • canRegionStationBeAdded

      public boolean canRegionStationBeAdded(Object regionKey, Object stationKey)
      Tells if a station can be added to a blocking region (all the stations that create or destroy jobs cannot be added)
      Specified by:
      canRegionStationBeAdded in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      stationKey - search's key for station
      Returns:
      true if the station can be added to specified region
    • canStationTypeBeBlocked

      protected boolean canStationTypeBeBlocked(String stationType)
      Tells if a station of a given type can be added to a blocking region (all the stations that create or destroy jobs cannot be added)
      Parameters:
      stationType - type of station to be added
      Returns:
      true if a station of that type can be added, false otherwise
    • addRegionStation

      public boolean addRegionStation(Object regionKey, Object stationKey)
      Adds a station to a blocking region
      Specified by:
      addRegionStation in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      stationKey - search's key for station
      Returns:
      true if the station has been added to specified region
    • removeRegionStation

      public void removeRegionStation(Object regionKey, Object stationKey)
      Removes a station from a blocking region
      Specified by:
      removeRegionStation in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      stationKey - search's key for station
    • getBlockingRegionStations

      public Set<Object> getBlockingRegionStations(Object regionKey)
      Returns a set of all the stations in a blocking region
      Specified by:
      getBlockingRegionStations in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      Returns:
      a set of all the stations in specified region
    • getStationBlockingRegion

      public Object getStationBlockingRegion(Object stationKey)
      Gets the blocking region of a station
      Specified by:
      getStationBlockingRegion in interface BlockingRegionDefinition
      Parameters:
      stationKey - search's key for station
      Returns:
      search's key for region or null if it is undefined
    • getBlockableStationKeys

      public Vector<Object> getBlockableStationKeys()
      Gets a vector of stations that can be added to a blocking region
      Specified by:
      getBlockableStationKeys in interface BlockingRegionDefinition
      Returns:
      a vector of stations that can be added to a blocking region
    • addBlockingDetails

      protected void addBlockingDetails(Object regionKey)
      Adds blocking region details, given the search key
    • deleteBlockingDetails

      protected void deleteBlockingDetails(Object regionKey)
      Deletes blocking region details, given the search key
    • addBlockingDetailsForClass

      protected void addBlockingDetailsForClass(Object classKey)
      Adds blocking region details for a class, given the search key
    • deleteBlockingDetailsForClass

      protected void deleteBlockingDetailsForClass(Object classKey)
      Deletes blocking region details for a class, given the search key
    • addRegionGroup

      public void addRegionGroup(Object regionKey, String name)
      Adds a new group to a blocking region
      Specified by:
      addRegionGroup in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      name - name of the new group
    • deleteRegionGroup

      public void deleteRegionGroup(Object regionKey, int index)
      Deletes a group from a blocking region
      Specified by:
      deleteRegionGroup in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
    • deleteAllRegionGroups

      public void deleteAllRegionGroups(Object regionKey)
      Deletes all the groups from a blocking region
      Specified by:
      deleteAllRegionGroups in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
    • getRegionGroupList

      public List<CommonModel.BlockingGroupData> getRegionGroupList(Object regionKey)
      Returns a list of the group data for a blocking region
      Specified by:
      getRegionGroupList in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      Returns:
      a list of the group data for specified region
    • getRegionGroupName

      public String getRegionGroupName(Object regionKey, int index)
      Gets the name of a group for a blocking region
      Specified by:
      getRegionGroupName in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
      Returns:
      name of the group
    • setRegionGroupName

      public void setRegionGroupName(Object regionKey, int index, String name)
      Sets the name of a group for a blocking region
      Specified by:
      setRegionGroupName in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
      name - name of the group
    • getRegionGroupCustomerConstraint

      public Integer getRegionGroupCustomerConstraint(Object regionKey, int index)
      Gets the customer number constraint for a blocking region and a group
      Specified by:
      getRegionGroupCustomerConstraint in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
      Returns:
      maximum number of allowed customers for specified group (-1 means infinity)
    • setRegionGroupCustomerConstraint

      public void setRegionGroupCustomerConstraint(Object regionKey, int index, Integer maxJobs)
      Sets the customer number constraint for a blocking region and a group
      Specified by:
      setRegionGroupCustomerConstraint in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
      maxJobs - maximum number of allowed customers for specified group (-1 means infinity)
    • getRegionGroupMemorySize

      public Integer getRegionGroupMemorySize(Object regionKey, int index)
      Gets the memory size constraint for a blocking region and a group
      Specified by:
      getRegionGroupMemorySize in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
      Returns:
      maximum size of allowed memory for specified group (-1 means infinity)
    • setRegionGroupMemorySize

      public void setRegionGroupMemorySize(Object regionKey, int index, Integer maxMemory)
      Sets the memory size constraint for a blocking region and a group
      Specified by:
      setRegionGroupMemorySize in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
      maxMemory - maximum size of allowed memory for specified group (-1 means infinity)
    • addClassIntoRegionGroup

      public void addClassIntoRegionGroup(Object regionKey, int index, Object classKey)
      Adds a class to a group for a blocking region
      Specified by:
      addClassIntoRegionGroup in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
      classKey - search's key for class
    • removeClassFromRegionGroup

      public void removeClassFromRegionGroup(Object regionKey, int index, Object classKey)
      Removes a class from a group for a blocking region
      Specified by:
      removeClassFromRegionGroup in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
      classKey - search's key for class
    • removeAllClassesFromRegionGroup

      public void removeAllClassesFromRegionGroup(Object regionKey, int index)
      Removes all the classes from a group for a blocking region
      Specified by:
      removeAllClassesFromRegionGroup in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
    • getRegionGroupClassList

      public List<Object> getRegionGroupClassList(Object regionKey, int index)
      Returns a list of classes in a group for a blocking region
      Specified by:
      getRegionGroupClassList in interface BlockingRegionDefinition
      Parameters:
      regionKey - search's key for region
      index - indexing number for group
      Returns:
      a list of classes in specified group
    • getTotalClosedClassPopulation

      public int getTotalClosedClassPopulation()
      Returns total population of closed classes
      Specified by:
      getTotalClosedClassPopulation in interface ClassDefinition
    • getClassSwitchMatrix

      public float getClassSwitchMatrix(Object stationKey, Object classInKey, Object classOutKey)
      Returns the cell (classInKey, classOutKey) of the class switch matrix for station stationKey.
      Specified by:
      getClassSwitchMatrix in interface StationDefinition
    • setClassSwitchMatrix

      public void setClassSwitchMatrix(Object stationKey, Object classInKey, Object classOutKey, float value)
      Sets the cell (classInKey, classOutKey) of the class switch matrix for station stationKey.
      Specified by:
      setClassSwitchMatrix in interface StationDefinition
    • getSemaphoreThreshold

      public Integer getSemaphoreThreshold(Object stationKey, Object classKey)
      Returns the threshold for semaphore stationKey and class classKey.
      Specified by:
      getSemaphoreThreshold in interface StationDefinition
    • setSemaphoreThreshold

      public void setSemaphoreThreshold(Object stationKey, Object classKey, Integer threshold)
      Sets the threshold for semaphore stationKey and class classKey.
      Specified by:
      setSemaphoreThreshold in interface StationDefinition
    • getTransitionModeListSize

      public int getTransitionModeListSize(Object stationKey)
      Returns the size of the mode list for transition stationKey.
      Specified by:
      getTransitionModeListSize in interface StationDefinition
    • getServerTypeKey

      public Object getServerTypeKey(Object stationKey, String name)
      Description copied from interface: StationDefinition
      This method returns server type key given name and its station
      Specified by:
      getServerTypeKey in interface StationDefinition
    • setStationSchedulingPolicy

      public void setStationSchedulingPolicy(Object key, String schedulingPolicy)
      Description copied from interface: StationDefinition
      This method sets scheduling policy of a station
      Specified by:
      setStationSchedulingPolicy in interface StationDefinition
    • getStationSchedulingPolicy

      public String getStationSchedulingPolicy(Object key)
      Description copied from interface: StationDefinition
      This method returns scheduling policy of a station
      Specified by:
      getStationSchedulingPolicy in interface StationDefinition
    • getServerType

      public ServerType getServerType(Object serverKey)
      Description copied from interface: StationDefinition
      This method returns Server Type given its key
      Specified by:
      getServerType in interface StationDefinition
    • isServerTypeKey

      public boolean isServerTypeKey(Object serverKey)
      Description copied from interface: StationDefinition
      This method returns true if it is a serverTypeKey
      Specified by:
      isServerTypeKey in interface StationDefinition
    • getServerTypes

      public List<ServerType> getServerTypes(Object stationKey)
      Description copied from interface: StationDefinition
      This method returns all server types of station
      Specified by:
      getServerTypes in interface StationDefinition
    • updateServerTypeIds

      public void updateServerTypeIds(Object stationKey)
    • getNumberOfDifferentServerTypes

      public int getNumberOfDifferentServerTypes(Object stationKey)
      Description copied from interface: StationDefinition
      This method returns the number of different server types
      Specified by:
      getNumberOfDifferentServerTypes in interface StationDefinition
    • getInfoForServerType

      public ServerType getInfoForServerType(Object stationKey, int index)
      Description copied from interface: StationDefinition
      This method returns a serverType given its station key and its order amongst the server types of that station
      Specified by:
      getInfoForServerType in interface StationDefinition
    • getServerTypeStationName

      public String getServerTypeStationName(Object serverKey)
      Description copied from interface: StationDefinition
      This method returns a server type name with respect to its station given its key
      Specified by:
      getServerTypeStationName in interface SimulationDefinition
      Specified by:
      getServerTypeStationName in interface StationDefinition
    • addServerType

      public void addServerType(Object stationKey, int change)
      Description copied from interface: StationDefinition
      This method adds a server type
      Specified by:
      addServerType in interface StationDefinition
    • addServerType

      public void addServerType(Object stationKey, String serverName, int serversPerServerType, List<Boolean> serverCompatibilities, boolean trimName)
    • deleteServerType

      public void deleteServerType(Object stationKey, int index)
      Description copied from interface: StationDefinition
      This method deletes a server type
      Specified by:
      deleteServerType in interface StationDefinition
    • updateNumOfServers

      public void updateNumOfServers(Object stationKey, int newTotal)
      Description copied from interface: StationDefinition
      This method updates number of servers of different server types in station
      Specified by:
      updateNumOfServers in interface StationDefinition
    • getServerTypeNames

      public List<String> getServerTypeNames(Object stationKey)
      Description copied from interface: StationDefinition
      This method returns the names of different server types
      Specified by:
      getServerTypeNames in interface StationDefinition
    • getHeterogeneousServersEnabled

      public Boolean getHeterogeneousServersEnabled(Object stationKey)
      Specified by:
      getHeterogeneousServersEnabled in interface StationDefinition
    • setHeterogeneousServersEnabled

      public void setHeterogeneousServersEnabled(Object key, Boolean enabled)
      Specified by:
      setHeterogeneousServersEnabled in interface StationDefinition
    • setStationVacationPolicy

      public void setStationVacationPolicy(Object stationKey, String vacationPolicy)
      Specified by:
      setStationVacationPolicy in interface StationDefinition
    • getStationVacationPolicy

      public String getStationVacationPolicy(Object stationKey)
      Specified by:
      getStationVacationPolicy in interface StationDefinition
    • getStationVacationParameters

      public VacationParameters getStationVacationParameters(Object stationKey)
      Specified by:
      getStationVacationParameters in interface StationDefinition
    • addTransitionMode

      public void addTransitionMode(Object stationKey, String name)
      Adds a new mode for transition stationKey.
      Specified by:
      addTransitionMode in interface StationDefinition
    • deleteTransitionMode

      public void deleteTransitionMode(Object stationKey, int modeIndex)
      Deletes a mode for transition stationKey.
      Specified by:
      deleteTransitionMode in interface StationDefinition
    • getTransitionModeName

      public String getTransitionModeName(Object stationKey, int modeIndex)
      Returns the name of mode modeIndex for transition stationKey.
      Specified by:
      getTransitionModeName in interface StationDefinition
    • getAllTransitionModeNames

      public List<String> getAllTransitionModeNames(Object stationKey)
      Returns the names of all the modes for transition stationKey.
      Specified by:
      getAllTransitionModeNames in interface StationDefinition
    • setTransitionModeName

      public void setTransitionModeName(Object stationKey, int modeIndex, String name)
      Sets the name of mode modeIndex for transition stationKey.
      Specified by:
      setTransitionModeName in interface StationDefinition
    • getEnablingCondition

      public Integer getEnablingCondition(Object stationKey, int modeIndex, Object stationInKey, Object classKey)
      Returns the entry (stationInKey, classKey) of the enabling condition for transition stationKey and mode modeIndex.
      Specified by:
      getEnablingCondition in interface StationDefinition
    • setEnablingCondition

      public void setEnablingCondition(Object stationKey, int modeIndex, Object stationInKey, Object classKey, Integer value)
      Sets the entry (stationInKey, classKey) of the enabling condition for transition stationKey and mode modeIndex.
      Specified by:
      setEnablingCondition in interface StationDefinition
    • getInhibitingCondition

      public Integer getInhibitingCondition(Object stationKey, int modeIndex, Object stationInKey, Object classKey)
      Returns the entry (stationInKey, classKey) of the inhibiting condition for transition stationKey and mode modeIndex.
      Specified by:
      getInhibitingCondition in interface StationDefinition
    • setInhibitingCondition

      public void setInhibitingCondition(Object stationKey, int modeIndex, Object stationInKey, Object classKey, Integer value)
      Sets the entry (stationInKey, classKey) of the inhibiting condition for transition stationKey and mode modeIndex.
      Specified by:
      setInhibitingCondition in interface StationDefinition
    • getResourceCondition

      public Integer getResourceCondition(Object stationKey, int modeIndex, Object stationInKey, Object classKey)
      Description copied from interface: StationDefinition
      Returns the entry (stationInKey, classKey) of the resource condition for server stationKey and modemodeIndex
      Specified by:
      getResourceCondition in interface StationDefinition
    • setResourceCondition

      public void setResourceCondition(Object stationKey, int modeIndex, Object stationInKey, Object classKey, Integer value)
      Description copied from interface: StationDefinition
      Sets the entry (stationInKey, classKey) of the resource condition for server stationKey and mode modeIndex.
      Specified by:
      setResourceCondition in interface StationDefinition
    • getNumberOfServers

      public Integer getNumberOfServers(Object stationKey, int modeIndex)
      Returns the number of servers for transition stationKey and mode modeIndex.
      Specified by:
      getNumberOfServers in interface StationDefinition
    • setNumberOfServers

      public void setNumberOfServers(Object stationKey, int modeIndex, Integer number)
      Sets the number of servers for transition stationKey and mode modeIndex.
      Specified by:
      setNumberOfServers in interface StationDefinition
    • getFiringTimeDistribution

      public Object getFiringTimeDistribution(Object stationKey, int modeIndex)
      Returns the firing time distribution for transition stationKey and mode modeIndex.
      Specified by:
      getFiringTimeDistribution in interface StationDefinition
    • setFiringTimeDistribution

      public void setFiringTimeDistribution(Object stationKey, int modeIndex, Object distribution)
      Sets the firing time distribution for transition stationKey and mode modeIndex.
      Specified by:
      setFiringTimeDistribution in interface StationDefinition
    • getFiringPriority

      public Integer getFiringPriority(Object stationKey, int modeIndex)
      Returns the firing priority for transition stationKey and mode modeIndex.
      Specified by:
      getFiringPriority in interface StationDefinition
    • setFiringPriority

      public void setFiringPriority(Object stationKey, int modeIndex, Integer priority)
      Sets the firing priority for transition stationKey and mode modeIndex.
      Specified by:
      setFiringPriority in interface StationDefinition
    • getFiringWeight

      public Double getFiringWeight(Object stationKey, int modeIndex)
      Returns the firing weight for transition stationKey and mode modeIndex.
      Specified by:
      getFiringWeight in interface StationDefinition
    • setFiringWeight

      public void setFiringWeight(Object stationKey, int modeIndex, Double weight)
      Sets the firing weight for transition stationKey and mode modeIndex.
      Specified by:
      setFiringWeight in interface StationDefinition
    • getFiringOutcome

      public Integer getFiringOutcome(Object stationKey, int modeIndex, Object stationOutKey, Object classKey)
      Returns the entry (stationOutKey, classKey) of the firing outcome for transition stationKey and mode modeIndex.
      Specified by:
      getFiringOutcome in interface StationDefinition
    • setFiringOutcome

      public void setFiringOutcome(Object stationKey, int modeIndex, Object stationOutKey, Object classKey, Integer value)
      Sets the entry (stationOutKey, classKey) of the firing outcome for transition stationKey and mode modeIndex.
      Specified by:
      setFiringOutcome in interface StationDefinition
    • getUniqueClassName

      protected String getUniqueClassName(String name)
      Returns given name if a class with the same name does not exist or makes it unique
      Parameters:
      name - class name
      Returns:
      unique name
    • getUniqueStationName

      protected String getUniqueStationName(String name)
      Returns given name if a station with the same name does not exist or makes it unique
      Parameters:
      name - station name
      Returns:
      unique name
    • getUniqueRegionName

      protected String getUniqueRegionName(String name)
      Returns given name if a blocking region with the same name does not exist or makes it unique
      Parameters:
      name - blocking region name
      Returns:
      unique name
    • getUniqueTransitionModeName

      protected String getUniqueTransitionModeName(Object key, String name)
      Returns given name if a mode with the same name does not exist or makes it unique for a transition
      Parameters:
      key - station key
      name - mode name
      Returns:
      unique name
    • getWhatIfParallelism

      public Integer getWhatIfParallelism()
      Description copied from interface: SimulationDefinition
      Returns the number of simulations to be run in parallel during what if analysis.
      Specified by:
      getWhatIfParallelism in interface SimulationDefinition
      Returns:
      the number of simulations to be run in parallel during what if analysis.