Class Pcm2MarkovStrategy

  • All Implemented Interfaces:
    SolverStrategy

    public class Pcm2MarkovStrategy
    extends Object
    implements SolverStrategy
    This class performs a transformation from a PCM instance to a Markov Chain instance, and solves the resulting Markov Chain instance.
    • Constructor Detail

      • Pcm2MarkovStrategy

        public Pcm2MarkovStrategy​(PCMSolverWorkflowRunConfiguration configuration)
        The constructor.
        Parameters:
        configuration - launch configuration parameters
    • Method Detail

      • getSolvedValue

        public MarkovTransformationResult getSolvedValue()
        Retrieves the Markov transformation results. If the PCM instance has multiple usage scenarios, only the results for the first usage scenario are returned.
        Returns:
        the Markov transformation results
      • loadTransformedModel

        public void loadTransformedModel​(String fileName)
        Loads an already existing Markov Chain from a given XMI file. Not yet implemented.
        Specified by:
        loadTransformedModel in interface SolverStrategy
        Parameters:
        fileName - the name of the XMI file
      • solve

        public void solve()
        Solves the Markov Chain which has been created as a result of the transformation or has been loaded from an XMI file.
        Specified by:
        solve in interface SolverStrategy
      • storeTransformedModel

        public void storeTransformedModel​(String fileName)
        Saves the Markov Chain resulting from the transformation into an XMI file. If the PCM instance has multiple usage scenarios, only the results for the first usage scenario are written into the file.
        Specified by:
        storeTransformedModel in interface SolverStrategy
        Parameters:
        fileName - the name of the XMI file to create
      • transform

        public void transform​(PCMInstance model)
        Transforms a PCM instance into a Markov Chain instance. The transformation is performed either as a single transformation, or as a repeated transformation to perform sensitivity analysis.
        Specified by:
        transform in interface SolverStrategy
        Parameters:
        model - the input PCM instance