Class: Google::Apis::SafebrowsingV5::GoogleSecuritySafebrowsingV5ThreatUrl

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/safebrowsing_v5/classes.rb,
lib/google/apis/safebrowsing_v5/representations.rb,
lib/google/apis/safebrowsing_v5/representations.rb

Overview

A URL matching one or more threats.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleSecuritySafebrowsingV5ThreatUrl

Returns a new instance of GoogleSecuritySafebrowsingV5ThreatUrl.



609
610
611
# File 'lib/google/apis/safebrowsing_v5/classes.rb', line 609

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#threat_typesArray<String>

Unordered list. The unordered list of threat that the URL is classified as. Corresponds to the JSON property threatTypes

Returns:

  • (Array<String>)


602
603
604
# File 'lib/google/apis/safebrowsing_v5/classes.rb', line 602

def threat_types
  @threat_types
end

#urlString

The requested URL that was matched by one or more threats. Corresponds to the JSON property url

Returns:

  • (String)


607
608
609
# File 'lib/google/apis/safebrowsing_v5/classes.rb', line 607

def url
  @url
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



614
615
616
617
# File 'lib/google/apis/safebrowsing_v5/classes.rb', line 614

def update!(**args)
  @threat_types = args[:threat_types] if args.key?(:threat_types)
  @url = args[:url] if args.key?(:url)
end