SSHKit::HostWithUsernameAndPortParser

@private

Public Class Methods

suitable?(host_string) click to toggle source
# File lib/sshkit/host.rb, line 138
def self.suitable?(host_string)
  host_string.match /@.*:\d+/
end

Public Instance Methods

hostname() click to toggle source
# File lib/sshkit/host.rb, line 144
def hostname
  @host_string.split(/:|@/)[1]
end
port() click to toggle source
# File lib/sshkit/host.rb, line 147
def port
  @host_string.split(/:|@/)[2].to_i
end
username() click to toggle source
# File lib/sshkit/host.rb, line 141
def username
  @host_string.split(/:|@/)[0]
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.