public abstract class AbstractSimulatedResourceContainer
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected java.util.HashMap<java.lang.String,java.lang.String> |
activeResourceProvidedInterfaces |
protected java.util.HashMap<java.lang.String,AbstractScheduledResource> |
activeResources |
protected static org.apache.log4j.Logger |
LOGGER |
protected java.lang.String |
myContainerID |
protected SimuComModel |
myModel |
Constructor and Description |
---|
AbstractSimulatedResourceContainer(SimuComModel myModel,
java.lang.String myContainerID) |
Modifier and Type | Method and Description |
---|---|
java.util.Collection<AbstractScheduledResource> |
getActiveResources()
Retrieves all active resources in this resource container.
|
java.util.HashMap<java.lang.String,AbstractScheduledResource> |
getAllActiveResources()
Retrieves the HashMap with all all active resources in this resource container.
|
java.util.List<AbstractScheduledResource> |
getFailedResources()
Retrieves all active resources in this resource container which are currently unavailable.
|
java.lang.String |
getResourceContainerID() |
void |
loadActiveResource(SimuComSimProcess requestingProcess,
int resourceServiceID,
java.lang.String typeID,
double demand)
Demand processing of a resource demand by a given type of active
resources In future versions this has to control schedulers of resource
types which exist in multiple instances
|
void |
loadActiveResource(SimuComSimProcess requestingProcess,
java.lang.String typeID,
double demand)
Demand processing of a resource demand by a given type of active resources In future versions
this has to control schedulers of resource types which exist in multiple instances
|
void |
loadActiveResource(SimuComSimProcess requestingProcess,
java.lang.String providedInterfaceID,
int resourceServiceID,
double demand)
Demand processing of a resource demand by a given type of active resource and a resource
interface operation
|
void |
loadActiveResource(SimuComSimProcess requestingProcess,
java.lang.String providedInterfaceID,
int resourceServiceID,
java.util.Map<java.lang.String,java.io.Serializable> parameterMap,
double demand)
Demand processing of a resource demand by a given type of active resource and a resource
interface operation and additional parameters which can be used in an active resource
|
protected static final org.apache.log4j.Logger LOGGER
protected final SimuComModel myModel
protected final java.lang.String myContainerID
protected java.util.HashMap<java.lang.String,AbstractScheduledResource> activeResources
protected final java.util.HashMap<java.lang.String,java.lang.String> activeResourceProvidedInterfaces
public AbstractSimulatedResourceContainer(SimuComModel myModel, java.lang.String myContainerID)
public void loadActiveResource(SimuComSimProcess requestingProcess, java.lang.String typeID, double demand)
requestingProcess
- The thread requesting the processing of a resource demandtypeID
- ID of the resource type to which the demand is directed. Same as the PCM resource
type IDsdemand
- The demand in units processable by the resource. The resource is responsible
itself for converting this demand into time spanspublic void loadActiveResource(SimuComSimProcess requestingProcess, java.lang.String providedInterfaceID, int resourceServiceID, double demand)
requestingProcess
- The thread requesting the processing of a resource demandtypeID
- ID of the resource provided interface to which the demand is directed.resourceServiceID
- the id of the resource service to be called.demand
- The demand in units processable by the resource. The resource is responsible
itself for converting this demand into time spanspublic void loadActiveResource(SimuComSimProcess requestingProcess, java.lang.String providedInterfaceID, int resourceServiceID, java.util.Map<java.lang.String,java.io.Serializable> parameterMap, double demand)
requestingProcess
- The thread requesting the processing of a resource demandprovidedInterfaceID
- ID of the resource provided interface to which the demand is directed.resourceServiceID
- the id of the resource service to be called.parameterMap
- Additional Parameters usable in an active resource. Parameters represented as
demand
- The demand in units processable by the resource. The resource is responsible
itself for converting this demand into time spanspublic java.util.Collection<AbstractScheduledResource> getActiveResources()
public java.util.HashMap<java.lang.String,AbstractScheduledResource> getAllActiveResources()
public java.util.List<AbstractScheduledResource> getFailedResources()
public java.lang.String getResourceContainerID()
public void loadActiveResource(SimuComSimProcess requestingProcess, int resourceServiceID, java.lang.String typeID, double demand)
requestingProcess
- The thread requesting the processing of a resource demandresourceServiceID
- the id of the resource service to be called.typeID
- ID of the resource type to which the demand is directed. Same
as the PCM resource type IDsdemand
- The demand in units processable by the resource. The resource
is responsible itself for converting this demand into time
spans