Chapter 50. IO Abstraction Layer (IO::Adapter Class)

Table of Contents
IO::Adapter Overview
IO::Adapter Methods
Argument Type Of Methods
File Map
Unixgroup Map
Nis Map
MySQL Map

IO::Adapter Overview

All IO of fml8 should use IO::Adapter class like vfs/vnode framework. For example, read/write member list, add/remove a user. The usage is like this:

use IO::Adapter;
$obj = new IO::Adapter $map, $map_params;
$obj->open || croak("cannot open $map");
while ($x = $obj->get_next_key()) { ... }
$obj->close;

$map is map:identifier. file: can be omitted. Currently available maps follow:

file:/var/spool/ml/elena/recipients
unix.group:root
nis.group:root
mysql:id
postgresql:id
ldap:id      

"file:" map is a normal file (text file). "unix.group:root" map is to read root entry in /etc/group file. "nis.group:root" map is to read root entry in NIS (YP). "mysql:id" map implies the use of MySQL. Parameters for MySQL access is defined in "mysql:id" entry. These paraemeters should be specified before calling "new IO::Adapter".

fml 8.0 (fml-devel) project homepage is www.fml.org/software/fml8/.
fml 4.0 project homepage is www.fml.org/software/fml4/.
about one floppy bsd routers, see www.bsdrouter.org/.
other free softwares are found at www.fml.org/software/.

author's homepage is www.fml.org/home/fukachan/.
Also, visit nuinui's world :) at www.nuinui.net.

For questions about FML, e-mail <fml-bugs@fml.org>.