class Google::Apis::CustomsearchV1::Result

A custom search result.

Attributes

cache_id[RW]

Indicates the ID of Google's cached version of the search result. Corresponds to the JSON property `cacheId` @return [String]

file_format[RW]

The file format of the search result. Corresponds to the JSON property `fileFormat` @return [String]

formatted_url[RW]

The URL displayed after the snippet for each search result. Corresponds to the JSON property `formattedUrl` @return [String]

html_formatted_url[RW]

The HTML-formatted URL displayed after the snippet for each search result. Corresponds to the JSON property `htmlFormattedUrl` @return [String]

html_snippet[RW]

The snippet of the search result, in HTML. Corresponds to the JSON property `htmlSnippet` @return [String]

html_title[RW]

The title of the search result, in HTML. Corresponds to the JSON property `htmlTitle` @return [String]

image[RW]

Image belonging to a custom search result. Corresponds to the JSON property `image` @return [Google::Apis::CustomsearchV1::Result::Image]

kind[RW]

A unique identifier for the type of current object. For this API, it is ` customsearch#result.` Corresponds to the JSON property `kind` @return [String]

labels[RW]

Encapsulates all information about [refinement labels](developers. google.com/custom-search/docs/xml_results). Corresponds to the JSON property `labels` @return [Array<Google::Apis::CustomsearchV1::Result::Label>]

mime[RW]

The MIME type of the search result. Corresponds to the JSON property `mime` @return [String]

pagemap[RW]

Contains [PageMap](developers.google.com/custom-search/docs/ structured_data#pagemaps) information for this search result. Corresponds to the JSON property `pagemap` @return [Hash<String,Object>]

snippet[RW]

The snippet of the search result, in plain text. Corresponds to the JSON property `snippet` @return [String]

title[RW]

The title of the search result, in plain text. Corresponds to the JSON property `title` @return [String]

Public Class Methods

new(**args) click to toggle source
# File lib/google/apis/customsearch_v1/classes.rb, line 227
def initialize(**args)
   update!(**args)
end

Public Instance Methods

update!(**args) click to toggle source

Update properties of this object

# File lib/google/apis/customsearch_v1/classes.rb, line 232
def update!(**args)
  @cache_id = args[:cache_id] if args.key?(:cache_id)
  @display_link = args[:display_link] if args.key?(:display_link)
  @file_format = args[:file_format] if args.key?(:file_format)
  @formatted_url = args[:formatted_url] if args.key?(:formatted_url)
  @html_formatted_url = args[:html_formatted_url] if args.key?(:html_formatted_url)
  @html_snippet = args[:html_snippet] if args.key?(:html_snippet)
  @html_title = args[:html_title] if args.key?(:html_title)
  @image = args[:image] if args.key?(:image)
  @kind = args[:kind] if args.key?(:kind)
  @labels = args[:labels] if args.key?(:labels)
  @link = args[:link] if args.key?(:link)
  @mime = args[:mime] if args.key?(:mime)
  @pagemap = args[:pagemap] if args.key?(:pagemap)
  @snippet = args[:snippet] if args.key?(:snippet)
  @title = args[:title] if args.key?(:title)
end