PosSharp v1.2.0 API Reference

--- #### [PosSharp\.Core](PosSharp.Core 'PosSharp\.Core') ### [PosSharp\.Core\.Lifecycle](PosSharp.Core.Lifecycle 'PosSharp\.Core\.Lifecycle').[IUposLifecycleHandler](PosSharp.Core.Lifecycle.IUposLifecycleHandler 'PosSharp\.Core\.Lifecycle\.IUposLifecycleHandler') ## IUposLifecycleHandler\.ValidateTransition\(ControlState, ControlState\) Method Validates whether a transition to a specific state is allowed from the current state\. ```csharp void ValidateTransition(PosSharp.Abstractions.ControlState currentState, PosSharp.Abstractions.ControlState targetState); ``` #### Parameters `currentState` [PosSharp\.Abstractions\.ControlState](https://learn.microsoft.com/en-us/dotnet/api/possharp.abstractions.controlstate 'PosSharp\.Abstractions\.ControlState') The current logical state\. `targetState` [PosSharp\.Abstractions\.ControlState](https://learn.microsoft.com/en-us/dotnet/api/possharp.abstractions.controlstate 'PosSharp\.Abstractions\.ControlState') The target logical state\. #### Exceptions [UposStateException](PosSharp.Core.UposStateException 'PosSharp\.Core\.UposStateException') Thrown if the transition is invalid\.