# `MingaAgent.Tool.Output.Range`
[🔗](https://github.com/jsmestad/minga/blob/main/lib/minga_agent/tool/output/range.ex#L1)

Explicit zero-based bounds for a full capture, requested slice, or retained page.

# `kind`

```elixir
@type kind() :: :full | :requested | :page | :captured_prefix
```

# `t`

```elixir
@type t() :: %MingaAgent.Tool.Output.Range{
  count: non_neg_integer(),
  kind: kind(),
  start: non_neg_integer(),
  total: total(),
  unit: unit()
}
```

# `total`

```elixir
@type total() :: non_neg_integer() | :unknown
```

# `unit`

```elixir
@type unit() :: :bytes | :lines | :items
```

# `new`

```elixir
@spec new(kind(), unit(), non_neg_integer(), non_neg_integer(), total()) ::
  {:ok, t()} | {:error, :invalid_range}
```

Builds valid bounds. A known total must contain the selected interval.

---

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