Barrelfish
|
Blocking I/O API for terminal client library. More...
Macros | |
#define | TERM_CLIENT_EOL_CHAR '\n' |
Functions | |
errval_t | term_client_blocking_init (struct term_client *client, struct capref sessionid) |
Initialize a connection to a terminal server and block until connection is established. More... | |
void | term_client_blocking_exit (struct term_client *client) |
Tear down connection to terminal server. More... | |
errval_t | term_client_blocking_read (struct term_client *client, char *data, size_t length, size_t *read) |
Blocking read from a terminal. More... | |
errval_t | term_client_blocking_write (struct term_client *client, const char *data, size_t length, size_t *written) |
Blocking write to a terminal. More... | |
errval_t | term_client_blocking_config (struct term_client *client, enum TerminalConfig opt, size_t arg) |
Send a configuration command to the terminal server. More... | |
Blocking I/O API for terminal client library.
#define TERM_CLIENT_EOL_CHAR '\n' |
Character that is used by libterm_client to determine end of line.
errval_t term_client_blocking_config | ( | struct term_client * | client, |
enum TerminalConfig | opt, | ||
size_t | arg | ||
) |
Send a configuration command to the terminal server.
client | Terminal client state. |
opt | Configuration option. |
arg | Optional argument. |
Dispatches the config waitset until configuration message is sent.
void term_client_blocking_exit | ( | struct term_client * | client | ) |
Tear down connection to terminal server.
client | Terminal client state. |
Dispatches the control waitset until the message is sent.
errval_t term_client_blocking_init | ( | struct term_client * | client, |
struct capref | session_id | ||
) |
Initialize a connection to a terminal server and block until connection is established.
client | Terminal client state, initialized by function to default values. |
session_id | The session the domain is part of. |
Dispatches the monitor waitset until all the bindings to the terminal server are established.
errval_t term_client_blocking_read | ( | struct term_client * | client, |
char * | data, | ||
size_t | length, | ||
size_t * | read | ||
) |
Blocking read from a terminal.
client | Terminal client state. |
data | Buffer to hold read characters. |
length | The number of characters to read. |
read | Number of characters read. This might be less than length if line_mode is enabled and the end of line was reached or if an error occurred. |
Dispatches the read if no data is available.
errval_t term_client_blocking_write | ( | struct term_client * | client, |
const char * | data, | ||
size_t | length, | ||
size_t * | written | ||
) |
Blocking write to a terminal.
client | Terminal client state. |
data | Buffer holding characters to write. |
length | The number of characters to write. |
written | Number of characters written. This might be less than length if an error occurred. |
Dispatches the write waitset until data is sent.