Documentation

Net::Socket::ReadLine

Method in Socket

bool ReadLine(string&out str)

Attempts to read up until the next newline character, and outputs the string (including the newline character) in str. If no newline character is encountered, it will return false, leave str unmodified, and no bytes will be consumed from the buffer. Note that this function will buffer 256 extra application bytes from the socket at a time: if your lines are longer than 256 bytes, you may have to call this multiple times. If this is a problem for you, you may have to re-consider your protocol design.

string str

Returns bool