Class: Pennyworth::Loaders::Rodauth

Inherits:
Object
  • Object
show all
Defined in:
lib/pennyworth/loaders/rodauth.rb

Overview

Loads Rodauth documentation by scraping the web page.

Instance Method Summary collapse

Constructor Details

#initialize(model: Models::Rodauth) ⇒ Rodauth

Returns a new instance of Rodauth.



16
17
18
19
# File 'lib/pennyworth/loaders/rodauth.rb', line 16

def initialize(model: Models::Rodauth, **)
  @model = model
  super(**)
end

Instance Method Details

#call(uri) ⇒ Object



21
22
23
# File 'lib/pennyworth/loaders/rodauth.rb', line 21

def call uri
  read(uri).each.with_object([]) { |item, entries| entries.append record_for(item) }
end