os: implement os.(*File).WriteAt (#3697)

os: implement os.(*File).WriteAt

Signed-off-by: Achille Roussel <achille.roussel@gmail.com>
This commit is contained in:
Achille
2023-05-05 00:40:15 -07:00
committed by GitHub
parent 1d5c5ca2ef
commit 602f35a5ca
8 changed files with 152 additions and 17 deletions
+3
View File
@@ -58,6 +58,9 @@ type FileHandle interface {
// Write writes up to len(b) bytes to the file.
Write(b []byte) (n int, err error)
// WriteAt writes b to the file at the given absolute offset
WriteAt(b []byte, offset int64) (n int, err error)
// Close closes the file, making it unusable for further writes.
Close() (err error)
}