class VagrantPlugins::Openstack::HttpConfig
Constants
- UNSET_VALUE
Attributes
open_timeout[RW]
@return [Integer]
proxy[RW]
@return [Integer]
read_timeout[RW]
@return [Integer]
Public Class Methods
new()
click to toggle source
# File lib/vagrant-openstack-provider/config/http.rb, line 18 def initialize @open_timeout = UNSET_VALUE @read_timeout = UNSET_VALUE @proxy = UNSET_VALUE end
Public Instance Methods
finalize!()
click to toggle source
# File lib/vagrant-openstack-provider/config/http.rb, line 24 def finalize! @open_timeout = 60 if @open_timeout == UNSET_VALUE @read_timeout = 30 if @read_timeout == UNSET_VALUE @proxy = nil if @proxy == UNSET_VALUE end
merge(other)
click to toggle source
# File lib/vagrant-openstack-provider/config/http.rb, line 30 def merge(other) result = self.class.new [self, other].each do |obj| obj.instance_variables.each do |key| next if key.to_s.start_with?('@__') value = obj.instance_variable_get(key) result.instance_variable_set(key, value) if value != UNSET_VALUE end end result end