Class: Mihari::Structs::Urlscan::Result

Inherits:
Dry::Struct
  • Object
show all
Defined in:
lib/mihari/structs/urlscan.rb

Class Method Summary collapse

Class Method Details

.from_dynamic!(d) ⇒ Object



26
27
28
29
30
31
32
33
# File 'lib/mihari/structs/urlscan.rb', line 26

def self.from_dynamic!(d)
  d = Types::Hash[d]
  new(
    page: Page.from_dynamic!(d.fetch("page")),
    id: d.fetch("_id"),
    sort: d.fetch("sort")
  )
end