Module pibfi_io

Description

I/O subsystem of the Platonic Ideal Brainf*ck Interpreter.

Deals with the input and output servers, their filters, and their translators.

Function Index

Exported Functions
flush/1Flushes any pending output, even if it has not been translated yet.
input/1Retrieves the next character value from the input stream.
output/2Sends the given character value to the output stream.
server/1Spawned by start/1.
start/3Creates and spawns a new I/O subsystem.
stop/1Tells the I/O server to stop.
Internal Documented Functions
config/2Sets the various options of an I/O subsystem.
write/5Writes a character to the output, within the given constraints.

Exported Functions

flush/1

flush(pid()) -> ok

Flushes any pending output, even if it has not been translated yet.

input/1

input(pid()) -> integer() | nop

Retrieves the next character value from the input stream.

output/2

output(pid(), integer()) -> ok

Sends the given character value to the output stream.

server/1

server(IO) -> never_returns()

Spawned by start/1. Should not be called directly by user code.

start/3

start(Supervisor::pid(), [option()], CannedInput::string()) -> pid()

Creates and spawns a new I/O subsystem. For a description of the allowed options, see the documentation for the pibfi_options module.

stop/1

stop(pid()) -> ok

Tells the I/O server to stop.

Documented Internal Functions

config/2

config([option()], tape()) -> tape()

Sets the various options of an I/O subsystem.

write/5

write(iodevice(), Max::integer(), Min::integer(), Wrap::boolean(), char()) -> ok

Writes a character to the output, within the given constraints.