up: IO     index Zimbu documentation

INTERFACE IO.I_CharOrByteReader @public

summary

     

An interface for any class that can read a byte or a UTF-8 character.

Can be implemented to read one byte or character at a time from a file, from a string, etc.

$readChar() int @file  Reads a UTF-8 byte sequence and returns one character.
$readByte() int @file  Reads and returns one byte.
 

members (alphabetically)

     

FUNC $readByte() int @abstract @file

     

Reads and returns one byte.

When there is nothing to read returns IO.eof.

FUNC $readChar() int @abstract @file

     

Reads a UTF-8 byte sequence and returns one character.

When there is nothing to read returns IO.eof.

license

      Copyright 2009 Bram Moolenaar All Rights Reserved.

      Licensed under the Apache License, Version 2.0. See the LICENSE file or obtain a copy at: http://www.apache.org/licenses/LICENSE-2.0