class MiniDisc::Discover::Service
Attributes
host[R]
id[R]
port[R]
Public Class Methods
new(id, host, options = {})
click to toggle source
# File lib/minidisc/discover.rb, line 73 def initialize(id, host, options = {}) @id = id @host = host @port = options.fetch(:port, 8080) end
Public Instance Methods
<=>(other)
click to toggle source
# File lib/minidisc/discover.rb, line 79 def <=>(other) to_h <=> other.to_h end
to_h()
click to toggle source
# File lib/minidisc/discover.rb, line 83 def to_h { id: @id, host: @host, port: @port } end