Class: Mihari::Structs::Shodan::Location
- Inherits:
-
Dry::Struct
- Object
- Dry::Struct
- Mihari::Structs::Shodan::Location
- Defined in:
- lib/mihari/structs/shodan.rb
Instance Attribute Summary collapse
- #country_code ⇒ String? readonly
- #country_name ⇒ String? readonly
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
Class Method Details
Instance Method Details
#geolocation ⇒ Mihari::Geolocation?
18 19 20 21 22 23 24 25 |
# File 'lib/mihari/structs/shodan.rb', line 18 def geolocation return nil if country_name.nil? || country_code.nil? Mihari::Models::Geolocation.new( country: country_name, country_code: country_code ) end |