v/vlib/io/writer.v

14 lines
272 B
V
Raw Normal View History

module io
// Writer represents a stream of data that can be wrote to
pub interface Writer {
mut:
2022-04-15 14:35:35 +02:00
write(buf []u8) ?int
}
// RandomWriter represents a stream of data that can be wrote to
// at a random pos
pub interface RandomWriter {
2022-04-15 14:35:35 +02:00
write_to(pos u64, buf []u8) ?int
}