method
new
v2_5_5 -
Show latest stable
-
0 notes -
Class: Server
- 1_8_6_287
- 1_8_7_72
- 1_8_7_330
- 1_9_1_378
- 1_9_2_180
- 1_9_3_125 (0)
- 1_9_3_392 (0)
- 2_1_10 (-38)
- 2_2_9 (0)
- 2_4_6 (0)
- 2_5_5 (0)
- 2_6_3 (0)
- What's this?
new(gem_dirs, port, daemon, launch = nil, addresses = nil)
public
Hide source
# File lib/rubygems/server.rb, line 432 def initialize(gem_dirs, port, daemon, launch = nil, addresses = nil) Gem::RDoc.load_rdoc Socket.do_not_reverse_lookup = true @gem_dirs = Array gem_dirs @port = port @daemon = daemon @launch = launch @addresses = addresses logger = WEBrick::Log.new nil, WEBrick::BasicLog::FATAL @server = WEBrick::HTTPServer.new :DoNotListen => true, :Logger => logger @spec_dirs = @gem_dirs.map { |gem_dir| File.join gem_dir, 'specifications' } @spec_dirs.reject! { |spec_dir| !File.directory? spec_dir } reset_gems @have_rdoc_4_plus = nil end