Class: RSocks::TcpServer
- Inherits:
-
Object
- Object
- RSocks::TcpServer
- Defined in:
- lib/r_socks/tcp_server.rb
Instance Attribute Summary collapse
-
#config ⇒ Object
readonly
Returns the value of attribute config.
Instance Method Summary collapse
-
#initialize(host = '127.0.0.1', port = 8081) ⇒ TcpServer
constructor
A new instance of TcpServer.
- #run! ⇒ Object
Constructor Details
Instance Attribute Details
#config ⇒ Object (readonly)
Returns the value of attribute config.
8 9 10 |
# File 'lib/r_socks/tcp_server.rb', line 8 def config @config end |
Instance Method Details
#run! ⇒ Object
16 17 18 19 20 21 22 |
# File 'lib/r_socks/tcp_server.rb', line 16 def run! begin start_tcp_server rescue Interrupt puts "\nr_socks TPC main server closed now...." end end |