# `Trogon.Commanded.ConsistencyPolicy.VersionedData`
[🔗](https://github.com/straw-hat-team/beam-monorepo/blob/trogon_commanded@v1.0.1/apps/trogon_commanded/lib/trogon/commanded/consistency_policy/versioned_data.ex#L1)

Wraps query result data with its version number.

The version represents the projection's event stream version at the time
of the read, indicating how up-to-date the data is.

# `t`

```elixir
@type t() :: %Trogon.Commanded.ConsistencyPolicy.VersionedData{
  data: term(),
  version: version()
}
```

Wraps query result data with its projection version.

# `version`

```elixir
@type version() :: non_neg_integer()
```

Event stream version at read time.

# `new`

```elixir
@spec new(version(), term()) :: t()
```

---

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