StringIO.flush

You're seeing just the function flush, go back to StringIO module for more information.

Specs

flush(pid()) :: binary()

Flushes the output buffer and returns its current contents.

Examples

iex> {:ok, pid} = StringIO.open("in")
iex> IO.write(pid, "out")
iex> StringIO.flush(pid)
"out"
iex> StringIO.contents(pid)
{"in", ""}