# `Statifier.Effect.Trace.EventDequeued`
[🔗](https://github.com/riddler/statifier-ex/blob/v2.0.0/lib/statifier/effect/trace/event_dequeued.ex#L1)

Trace payload for `{:trace, %__MODULE__{}}` - emitted when an external or
internal event is selected for processing (`docs/observability.md`
constraint 2's "event dequeued" row). `event` is the dequeued
`Statifier.Event.t()`; `from` names which queue it came off.

Built with `new/2`, never a struct literal, so `macrostep`/`microstep`/
`round` are always stamped from the `Statifier.MachineState` at hand and
no call site can forget or duplicate them.

# `t`

```elixir
@type t() :: %Statifier.Effect.Trace.EventDequeued{
  event: Statifier.Event.t(),
  from: :external | :internal,
  macrostep: non_neg_integer(),
  microstep: non_neg_integer(),
  round: non_neg_integer()
}
```

# `new`

```elixir
@spec new(machine_state :: Statifier.MachineState.t(), fields :: keyword()) :: t()
```

Stamps `macrostep`/`microstep`/`round` from `machine_state` and sets
`fields` (`:event`, `:from`).

---

*Consult [api-reference.md](api-reference.md) for complete listing*
