diff --git a/README.md b/README.md index 7d04a49..2c99039 100644 --- a/README.md +++ b/README.md @@ -80,7 +80,7 @@ A limit group is a way of enforcing a cap over a set of limits with the guarante **initialize(\*limits)** -Constructor for `TrafficJam::Limit` takes either an array or splat of limits. +Constructor for `TrafficJam::Limit` takes either an array or splat of limits or other limit groups. **increment(amount = 1)** @@ -98,6 +98,10 @@ Increment the limits by the given number. Raises `TrafficJam::LimitExceededError Return whether incrementing by the given amount would exceed any limit. Does not change amount used. +**limit_exceeded(amount = 1)** + +Return the first `TrafficJam::Limit` that would be exceeded by this amount or `nil` if incrementing would be safe. + **reset** Sets limits to 0.