Method deprecated or moved
This method is deprecated or moved on the latest stable version.
The last existing version (v2_2_9) is shown here.
These similar methods exist in v2_5_5:
print(string)
public
Sends a string to the host.
This does not automatically append a newline to the string.
Embedded newlines may be converted and telnet command sequences escaped
depending upon the values of telnetmode, binmode, and telnet options set by
the host.
Show source
def print(string)
string = string.gsub(/#{IAC}/o, IAC + IAC) if @options["Telnetmode"]
if @options["Binmode"]
self.write(string)
else
if @telnet_option["BINARY"] and @telnet_option["SGA"]
self.write(string.gsub(/\n/, CR))
elsif @telnet_option["SGA"]
self.write(string.gsub(/\n/, CR + NULL))
else
self.write(string.gsub(/\n/, EOL))
end
end
end