Sha256: 844aed8f967638cb560549a27a02c255c8d803dfb13fee5a53c0f681e12e8905
Contents?: true
Size: 760 Bytes
Versions: 4
Compression:
Stored size: 760 Bytes
Contents
# * George Moschovitis <gm@navel.gr> # (c) 2004-2005 Navel, all rights reserved. # $Id: conf.rb 1 2005-04-11 11:04:30Z gmosx $ require 'glue/flexob' require 'nitro/dispatcher' module Nitro # Configuration. class Conf < Flexob def initialize(options) unless options.is_a?(Hash) raise ArgumentError.new('An options hash is required!') end # Default configuration parameters. hash = { :name => 'Nitro', :host => '0.0.0.0', # this is accessible as localhost on windows. :port => 9999, :dispatcher => Dispatcher.new, :template_root => 'templates', :public_root => 'public' } hash.update(options) super(hash) end def mount(name, options = {}) $nitro_mount_options = options require_part(name) end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
nitro-0.16.0 | lib/nitro/conf.rb |
nitro-0.17.0 | lib/nitro/conf.rb |
nitro-0.18.1 | lib/nitro/conf.rb |
nitro-0.18.0 | lib/nitro/conf.rb |