Files
test_demo/MX-PD-盘古 - new/PanGu.DieBonderApp/MainShell/Process/ChipPreparation/CurrentChipStateService.cs

28 lines
866 B
C#
Raw Normal View History

using MainShell.ProcessResult;
using System;
namespace MainShell.Process
{
public class CurrentChipStateService
{
private readonly ProcessResultManager _processResultManager;
private CurrentChipLifecycleState _currentState;
public CurrentChipStateService(ProcessResultManager processResultManager)
{
_processResultManager = processResultManager ?? throw new ArgumentNullException(nameof(processResultManager));
_currentState = _processResultManager.CurrentChipState.State;
}
public CurrentChipLifecycleState CurrentState
{
get { return _currentState; }
}
public void SetState(CurrentChipLifecycleState chipState)
{
_currentState = chipState;
_processResultManager.SaveCurrentChipState(chipState);
}
}
}