# `DripDrop.Enrollment`
[🔗](https://github.com/agoodway/dripdrop/blob/v0.1.0/lib/dripdrop/enrollment.ex#L1)

A subscriber's lifecycle through a sequence.

# `allowed_transition?`

```elixir
@spec allowed_transition?(binary(), binary()) :: boolean()
```

Returns true when an enrollment can move from `state` to `next_state`.

# `changeset`

```elixir
@spec changeset(Ecto.Schema.t(), map()) :: Ecto.Changeset.t()
```

Builds a changeset for an enrollment lifecycle row.

# `transition_changeset`

```elixir
@spec transition_changeset(Ecto.Schema.t(), binary()) :: Ecto.Changeset.t()
```

Builds a state-transition changeset when the transition is allowed.

---

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