Class: URI::DRuby
Constant Summary collapse
- SCHEME =
'druby'
- DEFAULT_HOST =
'localhost'
- DEFAULT_PORT =
0
- DEFAULT_QUERY =
''
- COMPONENT =
[ :scheme, :host, :port ].freeze
Class Method Summary collapse
Methods inherited from Generic
#add_query, #checkout, #commit, #mk_custom_opts, #pathname, #pathname=, #save, #to_uri, #to_yaml_string, yaml_load
Class Method Details
.build(args) ⇒ Object
18 19 20 21 22 23 24 25 26 27 |
# File 'lib/uri/druby.rb', line 18 def self.build(args) if args.is_a?(Array) args << DEFAULT_HOST if args.size < 1 args << DEFAULT_PORT if args.size < 2 elsif args.is_a?(Hash) args[:host] = DEFAULT_HOST if args[:host].nil? args[:port] = DEFAULT_PORT if args[:port].nil? end return super(Util::make_components_hash(self, args)) end |