Home

News

International

Screen Shots

Documentation

Download

Build

License

Credits

Contact

SourceForge Project

Tintware Documentation : Tint Programming Language : Tint Reference : Ports and Processes : port.get

Syntax

#(%port.get-one)
#(%port.get-one,%nomore)
#(%port.get-one,%nomore,%timeout)
#(%port.get-n,%n)
#(%port.get-n,%n,%nomore)
#(%port.get-n,%n,%nomore,%timeout)

%port is any port. %nomore is what should be returned if there are no more characters available from the port or the timeout occurs. %timeout is how long to wait in seconds for enough characters to be available. %n is how many characters should be returned from the port.

Example

#(def,p,#(tint.socket))

#(#(p).connect,sourceforge.org,80)

#(#(p).put,GET / HTTP/1.1#(tint.byte,10)#(tint.byte,10))

#(#(p).get-one)
H
#(#(p).get-one)
T
#(#(p).get-one)
T
#(#(p).get-one)
P
#(#(p).get-n,20)
/1.1 400 Bad Request
#(#(p).close)