MCPcopy Create free account
hub / github.com/bytecodealliance/system-interface / append_vectored

Method append_vectored

src/fs/file_io_ext.rs:278–285  ·  view source on GitHub ↗

Is to `append` what `write_vectored` is to `write`.

(&self, bufs: &[IoSlice])

Source from the content-addressed store, hash-verified

276
277 /// Is to `append` what `write_vectored` is to `write`.
278 fn append_vectored(&self, bufs: &[IoSlice]) -> io::Result<usize> {
279 // By default, just append the first non-empty slice.
280 let buf = bufs
281 .iter()
282 .find(|b| !b.is_empty())
283 .map_or(&[][..], |b| &**b);
284 self.append(buf)
285 }
286
287 /// Is to `append_all` what `write_all_vectored` is to `write_all`.
288 fn append_all_vectored(&self, mut bufs: &mut [IoSlice]) -> io::Result<()> {

Callers

nothing calls this directly

Implementers 1

file_io_ext.rssrc/fs/file_io_ext.rs

Calls 1

appendMethod · 0.80

Tested by

no test coverage detected