Class: BuildTool::SshKey

Inherits:
Object
  • Object
show all
Defined in:
lib/build-tool/sshkey.rb

Overview

Encapsulates a ssh key

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, file = nil) ⇒ SshKey

Returns a new instance of SshKey.



7
8
9
10
# File 'lib/build-tool/sshkey.rb', line 7

def initialize(name, file = nil)
    @name = name
    @file = file
end

Instance Attribute Details

#fileObject

Returns the value of attribute file.



14
15
16
# File 'lib/build-tool/sshkey.rb', line 14

def file
  @file
end

#nameObject (readonly)

Returns the value of attribute name.



12
13
14
# File 'lib/build-tool/sshkey.rb', line 12

def name
  @name
end

Instance Method Details

#to_sObject



16
17
18
# File 'lib/build-tool/sshkey.rb', line 16

def to_s
    @file
end