/// <summary> /// Replays the model step starting at the serialized <paramref name="state" /> using the given /// <paramref name="replayInformation" />. /// </summary> /// <param name="state">The serialized state that the replay starts from.</param> /// <param name="replayInformation">The replay information required to compute the target state.</param> /// <param name="initializationStep">Indicates whether the initialization step should be replayed.</param> internal void Replay(byte *state, int[] replayInformation, bool initializationStep) { Requires.NotNull(replayInformation, nameof(replayInformation)); _choiceResolver.Clear(); _choiceResolver.PrepareNextState(); _choiceResolver.SetChoices(replayInformation); Deserialize(state); if (initializationStep) { ExecuteInitialStep(); } else { ExecuteStep(); } NotifyFaultActivations(); }