Module: Proxied::Shared::InstanceMethods

Defined in:
lib/proxied/shared.rb

Instance Method Summary collapse

Instance Method Details

#proxy_address(include_http: false) ⇒ Object



25
26
27
# File 'lib/proxied/shared.rb', line 25

def proxy_address(include_http: false)
  ::Proxied::Utilities.format_proxy_address(host: self.host, port: self.port, include_http: include_http)
end

#proxy_credentialsObject



29
30
31
# File 'lib/proxied/shared.rb', line 29

def proxy_credentials
  ::Proxied::Utilities.format_proxy_credentials(self.username, self.password)
end

#proxy_options_for_faradayObject



37
38
39
# File 'lib/proxied/shared.rb', line 37

def proxy_options_for_faraday
  ::Proxied::Utilities.proxy_options_for_faraday(host: self.host, port: self.port, username: self.username, password: self.password, auth_mode: self.auth_mode)
end

#proxy_switcher_import_formatObject



41
42
43
# File 'lib/proxied/shared.rb', line 41

def proxy_switcher_import_format
  ::Proxied::Utilities.proxy_switcher_import_format(host: self.host, port: self.port, username: self.username, password: self.password, country: self.country)
end

#socks_proxy_credentialsObject



33
34
35
# File 'lib/proxied/shared.rb', line 33

def socks_proxy_credentials
  ::Proxied::Utilities.socks_proxy_credentials(username: self.username, password: self.password)
end