Generic Instance Method

withUnsafeMutableBytes(_:)

Mutates the raw bytes in the data's buffer.

Declaration

mutating func withUnsafeMutableBytes<ResultType, ContentType>(_ body: (UnsafeMutablePointer<ContentType>) throws -> ResultType) rethrows -> ResultType

Discussion

This function assumes that you are mutating the contents.

See Also

Accessing Underlying Memory