class Fuzzyurl::Protocols

Constants

PORTS_BY_PROTOCOL
PROTOCOLS_BY_PORT

Public Class Methods

get_port(protocol) click to toggle source
# File lib/fuzzyurl/protocols.rb, line 15
def get_port(protocol)
  return nil unless protocol
  base_protocol = protocol.split('+').last
  PORTS_BY_PROTOCOL[base_protocol.to_s]
end
get_protocol(port) click to toggle source
# File lib/fuzzyurl/protocols.rb, line 21
def get_protocol(port)
  PROTOCOLS_BY_PORT[port.to_s]
end