Class: Net::SocketUri
- Inherits:
-
Object
- Object
- Net::SocketUri
- Defined in:
- lib/cangrejo/net/socket_uri.rb
Instance Method Summary collapse
- #empty? ⇒ Boolean
- #host ⇒ Object
- #hostname ⇒ Object
-
#initialize(_socket_path, _path) ⇒ SocketUri
constructor
A new instance of SocketUri.
- #password ⇒ Object
- #path ⇒ Object
- #port ⇒ Object
- #request_uri ⇒ Object
- #to_s ⇒ Object
- #user ⇒ Object
Constructor Details
#initialize(_socket_path, _path) ⇒ SocketUri
Returns a new instance of SocketUri.
4 5 6 7 |
# File 'lib/cangrejo/net/socket_uri.rb', line 4 def initialize(_socket_path, _path) @socket_path = _socket_path[7..-1] @path = _path end |
Instance Method Details
#empty? ⇒ Boolean
21 22 23 |
# File 'lib/cangrejo/net/socket_uri.rb', line 21 def empty? false end |
#host ⇒ Object
13 14 15 |
# File 'lib/cangrejo/net/socket_uri.rb', line 13 def host @socket_path end |
#hostname ⇒ Object
9 10 11 |
# File 'lib/cangrejo/net/socket_uri.rb', line 9 def hostname @socket_path end |
#password ⇒ Object
37 38 39 |
# File 'lib/cangrejo/net/socket_uri.rb', line 37 def password nil end |
#path ⇒ Object
29 30 31 |
# File 'lib/cangrejo/net/socket_uri.rb', line 29 def path @path end |
#port ⇒ Object
25 26 27 |
# File 'lib/cangrejo/net/socket_uri.rb', line 25 def port nil end |
#request_uri ⇒ Object
17 18 19 |
# File 'lib/cangrejo/net/socket_uri.rb', line 17 def request_uri @path end |
#to_s ⇒ Object
41 42 43 |
# File 'lib/cangrejo/net/socket_uri.rb', line 41 def to_s "#{@socket_path}::@path" end |
#user ⇒ Object
33 34 35 |
# File 'lib/cangrejo/net/socket_uri.rb', line 33 def user nil end |