Handbook
Glossary
gopher-get ( selector -- item-type byte-array )
Vocabulary
gopher
.
private
Inputs
selector
an
object
Outputs
item-type
an
object
byte-array
an
object
Definition
USING:
io
io.encodings.string
io.encodings.utf8
kernel
sequences
splitting
;
IN:
gopher.private
:
gopher-get
( selector -- item-type byte-array )
"/"
split1
""
or
[
first
]
dip
"?"
split1
[
"\t"
glue
]
when*
"\r\n"
append
utf8
encode
write
flush
read-contents
;