mirror of
https://github.com/apple/swift-nio
synced 2026-11-28 05:14:23 +00:00
Add a version of 'write' for 'ByteBuffer' (#2730)
* Add a version of 'write' for 'ByteBuffer' Motivation: At the moment 'WritableFileHandleProtocol' is in terms of `some Sequence<UInt8>`. To use a `ByteBuffer` users must pass in the readable view of the buffer, which is inconvenient. Modifications: - Add an extension to `WritableFileHandleProtocol` which takes a `ByteBuffer`. Result: Easier to use API * fix docs
This commit is contained in:
1 parent
9f63b12a05
commit
d8bf55d693
3 files changed
+49
-1
No files matched your search
@@ -4,7 +4,8 @@
|
||||
|
||||
### Write bytes to a file
|
||||
|
||||
- ``write(contentsOf:toAbsoluteOffset:)``
|
||||
- ``write(contentsOf:toAbsoluteOffset:)-57fnc``
|
||||
- ``write(contentsOf:toAbsoluteOffset:)-4na03``
|
||||
- ``bufferedWriter(startingAtAbsoluteOffset:capacity:)``
|
||||
|
||||
### Resize a file
|
||||
|
||||
Reference in new issue
Block a user