module Proxied::Shared::InstanceMethods
Public Instance Methods
proxy_address(include_protocol: false)
click to toggle source
# File lib/proxied/shared.rb, line 26 def proxy_address(include_protocol: false) case self.auth_mode.to_sym when :credentials ::Proxied::Utilities.format_proxy_address(host: self.host, port: self.port, protocol: self.protocol, include_protocol: include_protocol) when :url ::Proxied::Utilities.format_proxy_address(host: self.host, port: self.port, protocol: self.protocol, username: self.username, password: self.password, include_protocol: include_protocol) end end
proxy_credentials()
click to toggle source
# File lib/proxied/shared.rb, line 35 def proxy_credentials ::Proxied::Utilities.format_proxy_credentials(self.username, self.password) end
proxy_options_for_faraday()
click to toggle source
# File lib/proxied/shared.rb, line 43 def proxy_options_for_faraday ::Proxied::Utilities.proxy_options_for_faraday( host: self.host, port: self.port, protocol: self.protocol, username: self.username, password: self.password, auth_mode: self.auth_mode ) end
socks_proxy_credentials()
click to toggle source
# File lib/proxied/shared.rb, line 39 def socks_proxy_credentials ::Proxied::Utilities.socks_proxy_credentials(username: self.username, password: self.password) end