StateObject

public class StateObject : @unchecked Sendable

状态类

  • 状态名称,只读

    Declaration

    Swift

    public private(set) var name: String { get }
  • 即将进入block

    Declaration

    Swift

    public var willEnterBlock: (@MainActor @Sendable (StateTransition?) -> Void)?
  • 已进入block

    Declaration

    Swift

    public var didEnterBlock: (@MainActor @Sendable (StateTransition?) -> Void)?
  • 即将退出block

    Declaration

    Swift

    public var willExitBlock: (@MainActor @Sendable (StateTransition) -> Void)?
  • 已退出block

    Declaration

    Swift

    public var didExitBlock: (@MainActor @Sendable (StateTransition) -> Void)?
  • 从名称初始化

    Declaration

    Swift

    public init(name: String)