プログラミング言語SML#解説 3.7.1版
26.34 TEXT_IO
signature TEXT_IO = sig structure StreamIO : TEXT_STREAM_IO where type reader = TextPrimIO.reader where type writer = TextPrimIO.writer where type pos = TextPrimIO.pos type elem = StreamIO.elem type instream type outstream type vector = StreamIO.vector val canInput : instream * int -> int option val closeIn : instream -> unit val closeOut : outstream -> unit val endOfStream : instream -> bool val flushOut : outstream -> unit val getInstream : instream -> StreamIO.instream val getOutstream : outstream -> StreamIO.outstream val getPosOut : outstream -> StreamIO.out_pos val input : instream -> vector val input1 : instream -> elem option val inputAll : instream -> vector val inputLine : instream -> string option val inputN : instream * int -> vector val lookahead : instream -> elem option val mkInstream : StreamIO.instream -> instream val mkOutstream : StreamIO.outstream -> outstream val openAppend : string -> outstream val openIn : string -> instream val openOut : string -> outstream val openString : string -> instream val output : outstream * vector -> unit val output1 : outstream * elem -> unit val outputSubstr : outstream * substring -> unit val print : string -> unit val scanStream : ((Char.char, StreamIO.instream) StringCvt.reader Ψ-> (’a, StreamIO.instream) StringCvt.reader) Ψ-> instream Ψ-> ’a option val setInstream : instream * StreamIO.instream -> unit val setOutstream : outstream * StreamIO.outstream -> unit val setPosOut : outstream * StreamIO.out_pos -> unit val stdErr : outstream val stdIn : instream val stdOut : outstream end
ネストしたシグネチャ
-
•
TEXT_STREAM_IO (26.35)
シグネチャを実装するストラクチャ
-
•
TextIO : TEXT_IO