Class ProcessingResourceDescriptor

java.lang.Object
org.palladiosimulator.reliability.solver.pcm2markov.ProcessingResourceDescriptor

public class ProcessingResourceDescriptor extends Object
Describes the characteristics of a PCM processing resource with respect to its availability.
  • Constructor Details

    • ProcessingResourceDescriptor

      public ProcessingResourceDescriptor()
      The constructor.
  • Method Details

    • getCurrentState

      public MarkovResourceState getCurrentState()
      Gets the current resource state.
      Returns:
      the current state
    • getDefaultState

      public MarkovResourceState getDefaultState()
      Returns the default state of this resource.
      Returns:
      the default state
    • getResourceContainerId

      public String getResourceContainerId()
      Gets the id of the surrounding resource container.
      Returns:
      the id
    • getResourceContainerName

      public String getResourceContainerName()
      Gets the name of the surrounding resource container.
      Returns:
      the name
    • getStateProbability

      public Double getStateProbability(MarkovResourceState state)
      Retrieves the probability of a given resource state.
      Parameters:
      state - the resource state
      Returns:
      the probability
    • getType

      public MarkovResourceType getType()
      Retrieves the resource type.
      Returns:
      the resource type
    • isRequiredByContainer

      public boolean isRequiredByContainer()
      Retrieves the availability relation to the surrounding resource container.
      Returns:
      the availability relation to the surrounding resource container
    • setContainerId

      public void setContainerId(String resourceContainerId)
      Sets the id of the surrounding resource container.
      Parameters:
      resourceContainerId - the id to set
    • setContainerName

      public void setContainerName(String resourceContainerName)
      Sets the name of the surrounding resource container.
      Parameters:
      resourceContainerName - the name to set
    • setCurrentState

      public void setCurrentState(MarkovResourceState state)
      Sets the current resource state.
      Parameters:
      state - the state to set
    • setId

      public void setId(String typeId)
      Sets the resource type id.
      Parameters:
      typeId - the resource type id to set
    • setName

      public void setName(String typeName)
      Sets the resource type name.
      Parameters:
      typeName - the resource type name to set
    • setRequiredByContainer

      public void setRequiredByContainer(boolean requiredByContainer)
      Sets the availability relation to the surrounding resource container.
      Parameters:
      requiredByContainer - the availability relation to the surrounding resource container
    • setStateProbability

      public void setStateProbability(MarkovResourceState state, Double probability)
      Sets a probability for a given resource state.
      Parameters:
      state - the resource state
      probability - the probability
    • switchState

      public void switchState()
      Switches the state from either ProcessingResourceState.OK to ProcessingResourceState.NA or ProcessingResourceState.NA to ProcessingResourceState.OK.