ClosedRange

struct ClosedRange<Bound> where Bound : Comparable
  • Clamp value to the range

    Declaration

    Swift

    public func clamp(_ value: Bound) -> Bound

    Parameters

    value

    Value to clamp