resetBytes(in:)

Set a region of the data to 0.

iOS
8.0+
macOS
10.10+
tvOS
9.0+
watchOS
2.0+
mutating func resetBytes(in range: Range<Data.Index>)

Parameters

range

The range in the data to set to 0.

If range exceeds the bounds of the data, then the data is resized to fit.