Class: Zap::Dns::Server
- Inherits:
-
RubyDNS::Server
- Object
- RubyDNS::Server
- Zap::Dns::Server
- Defined in:
- lib/zap/dns/server.rb
Constant Summary collapse
- IN =
Resolv::DNS::Resource::IN
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.start(params = {}) ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/zap/dns/server.rb', line 9 def start params={} @address = '127.0.0.1' @port = params[:port] @port ||= 35553 @listen = [ [:udp, @address,@port],[:tcp,@address,@port] ] @server_class = self @asynchronous = false @server = RubyDNS::run_server asynchronous: @asynchronous, server_class: @server_class, listen: @listen end |