Class: TCPSocket::SOCKSConnectionPeerAddress
- Inherits:
-
String
- Object
- String
- TCPSocket::SOCKSConnectionPeerAddress
- Defined in:
- lib/socksify/tcpsocket.rb
Overview
string representation of the peer host address
Instance Attribute Summary collapse
-
#socks_password ⇒ Object
readonly
Returns the value of attribute socks_password.
-
#socks_port ⇒ Object
readonly
Returns the value of attribute socks_port.
-
#socks_server ⇒ Object
readonly
Returns the value of attribute socks_server.
-
#socks_username ⇒ Object
readonly
Returns the value of attribute socks_username.
Instance Method Summary collapse
-
#initialize(socks_server, socks_port, peer_host, socks_username = nil, socks_password = nil) ⇒ SOCKSConnectionPeerAddress
constructor
A new instance of SOCKSConnectionPeerAddress.
- #inspect ⇒ Object
- #peer_host ⇒ Object
Constructor Details
#initialize(socks_server, socks_port, peer_host, socks_username = nil, socks_password = nil) ⇒ SOCKSConnectionPeerAddress
Returns a new instance of SOCKSConnectionPeerAddress.
33 34 35 36 37 38 39 |
# File 'lib/socksify/tcpsocket.rb', line 33 def initialize(socks_server, socks_port, peer_host, socks_username = nil, socks_password = nil) @socks_server = socks_server @socks_port = socks_port @socks_username = socks_username @socks_password = socks_password super(peer_host) end |
Instance Attribute Details
#socks_password ⇒ Object (readonly)
Returns the value of attribute socks_password.
31 32 33 |
# File 'lib/socksify/tcpsocket.rb', line 31 def socks_password @socks_password end |
#socks_port ⇒ Object (readonly)
Returns the value of attribute socks_port.
31 32 33 |
# File 'lib/socksify/tcpsocket.rb', line 31 def socks_port @socks_port end |
#socks_server ⇒ Object (readonly)
Returns the value of attribute socks_server.
31 32 33 |
# File 'lib/socksify/tcpsocket.rb', line 31 def socks_server @socks_server end |
#socks_username ⇒ Object (readonly)
Returns the value of attribute socks_username.
31 32 33 |
# File 'lib/socksify/tcpsocket.rb', line 31 def socks_username @socks_username end |
Instance Method Details
#inspect ⇒ Object
41 42 43 |
# File 'lib/socksify/tcpsocket.rb', line 41 def inspect "#{self} (via #{@socks_server}:#{@socks_port})" end |
#peer_host ⇒ Object
45 46 47 |
# File 'lib/socksify/tcpsocket.rb', line 45 def peer_host to_s end |