djherbis / bufit

A moving buffer which supports multiple concurrent readers #golang
MIT License
32 stars 3 forks source link

Ensure Buffer conforms to Writer interface #4

Closed tmm1 closed 7 years ago

tmm1 commented 7 years ago

This exposes Len() and Discard() on Buffer, which makes it possible for users to query and limit the size of the underlying buffer.

djherbis commented 7 years ago

I'm going to close this request since I think it's obsolete now.

tmm1 commented 7 years ago

:+1:. It might still be worth adding Len() for visibility into the buffer, but that can be a separate PR later.

djherbis commented 7 years ago

Yeah Len() could be useful, it might need sync around it.

Sounds good.