Closes the buffer and releases any external resources contained by this buffer.
Closes the buffer and releases any external resources contained by this buffer. This method is idempotent.
Drain the buffer using the readLine
function to process each message in the buffer.
Drain the buffer using the readLine
function to process each message in the buffer.
This method works with scala.concurrent.Future objects and needs an scala.concurrent.ExecutionContext in scope
A function that takes a io.backchat.hookup.OutboundMessage and produces a scala.concurrent.Future of io.backchat.hookup.OperationResult
An scala.concurrent.ExecutionContext
A scala.concurrent.Future of io.backchat.hookup.OperationResult
Open this file buffer if not already opened.
Open this file buffer if not already opened. This method is idempotent.
Write a message to the buffer.
Write a message to the buffer. When the buffer is opened it will write a new line to the file When the buffer is closed it will open the buffer and then write the new line. When the buffer is being drained it will buffer to memory When an exception is thrown it will first buffer the message to memory and then rethrow the exception
The default file buffer. This is a file buffer that also has a memory buffer to which it writes when the file stream is being read out or if a write to the file failed.
This class has no maximum size or any limits attached to it yet. So it is possible for this class to exhaust the memory and/or disk space of the machine using this buffer.