NAME

SPVM::IO::Handle - I/O Handling

Description

SPVM::IO::Handle is the SPVM's IO::Handle class for I/O handling.

Usage

use IO::Handle;
my $handle = IO::Handle->new;
$handle->set_autoflush(1);

Instance Methods

Fields

autoflush

has autoflush : rw byte;

input_line_number

has input_line_number : ro int;

opened

has opened : ro protected int;

blocking_flag

has blocking_flag : rw protected int;

Class methods

new

static method new : IO::Handle ($options : object[]);

Instance Methods

init

method init : void ($options : object[] = undef);

close

method close : int ();

eof

method eof : int ();

fileno

method fileno : int ();

getc

method getc : int ();

print

method print : int ($string : string);

say

method say : int ($string : string);

printf

method printf : int ($format : string, $args : object[]...);

clearerr

method clearerr : void ();

error

method error : int ();

flush

method flush : int ();

ungetc

method ungetc : int ($c : int);

printflush

method printflush : int ($string : string);

truncate

method truncate : int ($legnth : long);

ioctl

method ioctl : int ($request : int, $request_arg : object = undef of Byte|Short|Int|Long|Float|Double|object);

sync

method sync : int ();

stat

method stat : int ($stat : Sys::IO::Stat);

getline

method getline : string ();

getlines

method getlines : string ();

fcntl

method fcntl : int ($command : int, $command_arg : object = undef of Int|Sys::IO::Flock|object);

blocking

method blocking : void ($blocking : int);

write

method write : int ($string : string, $length : int = -1, $offset : int = 0);

read

method read : int ($string : mutable string, $length : int = -1, $offset : int = 0);

Well Known Child Classes

IO::File

IO::File

IO::Socket

IO::Socket

IO::Socket::INET

IO::Socket::INET

See Also

IO::Handle

SPVM::IO::Handle is the Perl's IO::Handle porting to SPVM.

Copyright & License

Copyright (c) 2023 Yuki Kimoto

MIT License