muse_port.h File Reference

#include "muse_opcodes.h"

Include dependency graph for muse_port.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  muse_port_type_t
 Defines the Ports protocol. More...
struct  muse_port_buffer_t
 Every port is buffered for input as well as output. More...
struct  _muse_port_base_t
 The base port type. More...

Ports implementation API

void port_init (muse_port_base_t *p)
 Intended to be called inside a particular port's init function at port creation time.
void port_destroy (muse_port_base_t *p)
 Intended to be called inside a particular ports destroy function at port destruction time.
int port_getc (muse_port_base_t *p)
 Same protocol as the system getc function, but works with the given port.
int port_ungetc (int c, muse_port_base_t *p)
 Same protocol as the system ungetc function.
int port_putc (int c, muse_port_base_t *p)
 Same protocol as the system putc function.
void port_close (muse_port_base_t *p)
 Flushes the port and call's the port's close function to release system resources.
int port_eof (muse_port_base_t *port)
 Returns EOF if the port has reached end of stream.
size_t port_read (void *buffer, size_t nbytes, muse_port_base_t *port)
 Wraps the port specific read function.
size_t port_write (void *buffer, size_t nbytes, muse_port_base_t *port)
 Wraps the port specific write function.
int port_flush (muse_port_base_t *port)
 Writes any data pending in the port's output buffer and then calls the port-specific flush function.

Typedefs

typedef _muse_port_base_t muse_port_base_t
 The base port type.

Functions

void muse_define_builtin_fileport ()
 Adds all file port definitions such as "open-file".


Detailed Description

Author:
Srikumar K. S. (mailto:kumar@muvee.com)
Copyright (c) 2006 Jointly owned by Srikumar K. S. and muvee Technologies Pte. Ltd.

All rights reserved. See LICENSE.txt distributed with this source code or http://muvee-symbolic-expressions.googlecode.com/svn/trunk/LICENSE.txt for terms and conditions under which this software is provided to you.


Generated on Mon Sep 25 23:12:47 2006 for muSE by  doxygen 1.4.7