Skip to main content

AppLockRefusedEvent

This event is emitted when the app lock is refused, before the error is thrown. holder is the command holding the lock, as far as the state provider knows it.

@group

Events/State

Hierarchy

  • StateEvent<{ holder?: { commitId?: string; context?: string; lockId: string; takenAt?: number }; newestCommitId?: string; reason: held | not-held | state-moved | unfinished; refreshedCommitId?: string; stateFileNames?: string[] }>
    • AppLockRefusedEvent

Index

Constructors

Properties

Constructors

constructor

  • AppLockRefusedEvent(name?: string, payload?: { holder?: { commitId?: string; context?: string; lockId: string; takenAt?: number }; newestCommitId?: string; reason: held | not-held | state-moved | unfinished; refreshedCommitId?: string; stateFileNames?: string[] }): AppLockRefusedEvent
  • Parameters

    • optionalname: string

      The subject of the event, when the event type alone does not identify it.

    • optionalpayload: { holder?: { commitId?: string; context?: string; lockId: string; takenAt?: number }; newestCommitId?: string; reason: held | not-held | state-moved | unfinished; refreshedCommitId?: string; stateFileNames?: string[] }

      The event's data.

      • optionalholder: { commitId?: string; context?: string; lockId: string; takenAt?: number }
      • optionalnewestCommitId: string
      • reason: held | not-held | state-moved | unfinished
      • optionalrefreshedCommitId: string
      • optionalstateFileNames: string[]

    Returns AppLockRefusedEvent

Properties

readonlyinheritedheader

header: { sequence: number; timestamp: number }

When the event was created. sequence counts every event this process created, so it orders two events created in the same millisecond, and events a late listener receives replayed.


Type declaration

  • sequence: number
  • timestamp: number

readonlyinheritedname

name: string

The subject of the event, when the event type alone does not identify it - e.g. the class name on a registration event. Empty otherwise.

readonlyinheritedpayload

payload: { holder?: { commitId?: string; context?: string; lockId: string; takenAt?: number }; newestCommitId?: string; reason: held | not-held | state-moved | unfinished; refreshedCommitId?: string; stateFileNames?: string[] }

The event's data. Its shape is fixed by the event type.


Type declaration

  • optionalholder?: { commitId?: string; context?: string; lockId: string; takenAt?: number }
    • optionalcommitId?: string
    • optionalcontext?: string
    • lockId: string
    • optionaltakenAt?: number
  • optionalnewestCommitId?: string
  • reason: held | not-held | state-moved | unfinished
  • optionalrefreshedCommitId?: string
  • optionalstateFileNames?: string[]
Page Options