NAME
IO::Pty - Pseudo TTY object class
SYNOPSIS
use IO::Pty;
$pty = new IO::Pty;
$slave = $pty->slave;
foreach $val (1..10) {
print $pty "$val\n";
$_ = <$slave>;
print "$_";
}
close($slave);
DESCRIPTION
IO::Pty
provides an interface to allow the creation of a pseudo tty.
IO::Pty
inherits from IO::Handle
and so provide all the methods defined by the IO::Handle
package.
Please note that pty creation is very system-dependend. If you have problems, see IO::Tty for help.
CONSTRUCTOR
- new
-
The
new
contructor take no arguments and returns a new object which the master side of the pseudo tty.
METHODS
- slave
-
The
slave
method will return a newIO::Pty
object which represents the slave side of the pseudo tty. - ttyname
-
Returns the name of the pseudo tty. On UNIX machines this will be the pathname of the device.
SEE ALSO
MAILING LISTS
As this module is mainly used by Expect, support for it is available via the two Expect mailing lists, expectperl-announce and expectperl-discuss, at
http://lists.sourceforge.net/lists/listinfo/expectperl-announce
and
http://lists.sourceforge.net/lists/listinfo/expectperl-discuss
AUTHORS
Graham Barr <gbarr@pobox.com>
Based on original Ptty module by Nick Ing-Simmons <nik@tiuk.ti.com>
Now maintained by Roland Giersig <RGiersig@cpan.org>
COPYRIGHT
The C code used in the XS file is covered by the GNU GENERAL PUBLIC LICENSE, See COPYING
All other code is free software; you can redistribute it and/or modify it under the same terms as Perl itself.