Class: HrrRbSsh::Compat::OpenSSH::AuthorizedKeys
- Inherits:
-
Object
- Object
- HrrRbSsh::Compat::OpenSSH::AuthorizedKeys
- Includes:
- Enumerable
- Defined in:
- lib/hrr_rb_ssh/compat/openssh/authorized_keys.rb
Instance Method Summary collapse
- #each ⇒ Object
-
#initialize(data_str) ⇒ AuthorizedKeys
constructor
A new instance of AuthorizedKeys.
Constructor Details
#initialize(data_str) ⇒ AuthorizedKeys
Returns a new instance of AuthorizedKeys.
8 9 10 11 12 |
# File 'lib/hrr_rb_ssh/compat/openssh/authorized_keys.rb', line 8 def initialize data_str @public_keys = data_str.each_line.map{ |line| PublicKey.new line } end |
Instance Method Details
#each ⇒ Object
14 15 16 17 18 |
# File 'lib/hrr_rb_ssh/compat/openssh/authorized_keys.rb', line 14 def each @public_keys.each{ |public_key| yield public_key } end |