Class: Google::Apis::ContentV2_1::DatafeedTarget

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ DatafeedTarget

Returns a new instance of DatafeedTarget.



4001
4002
4003
# File 'lib/google/apis/content_v2_1/classes.rb', line 4001

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

Instance Attribute Details

#countryString

Deprecated. Use feedLabel instead. The country where the items in the feed will be included in the search index, represented as a CLDR territory code. Corresponds to the JSON property country

Returns:

  • (String)


3963
3964
3965
# File 'lib/google/apis/content_v2_1/classes.rb', line 3963

def country
  @country
end

#excluded_destinationsArray<String>

The list of destinations to exclude for this target (corresponds to cleared check boxes in Merchant Center). Products that are excluded from all destinations for more than 7 days are automatically deleted. Corresponds to the JSON property excludedDestinations

Returns:

  • (Array<String>)


3971
3972
3973
# File 'lib/google/apis/content_v2_1/classes.rb', line 3971

def excluded_destinations
  @excluded_destinations
end

#feed_labelString

Feed label for the DatafeedTarget. Either country or feedLabel is required. If both feedLabel and country is specified, the values must match. Must be less than or equal to 20 uppercase letters (A-Z), numbers (0-9), and dashes (-). Corresponds to the JSON property feedLabel

Returns:

  • (String)


3979
3980
3981
# File 'lib/google/apis/content_v2_1/classes.rb', line 3979

def feed_label
  @feed_label
end

#included_destinationsArray<String>

The list of destinations to include for this target (corresponds to checked check boxes in Merchant Center). Default destinations are always included unless provided in excludedDestinations. Corresponds to the JSON property includedDestinations

Returns:

  • (Array<String>)


3987
3988
3989
# File 'lib/google/apis/content_v2_1/classes.rb', line 3987

def included_destinations
  @included_destinations
end

#languageString

The two-letter ISO 639-1 language of the items in the feed. Must be a valid language for targets[].country. Corresponds to the JSON property language

Returns:

  • (String)


3993
3994
3995
# File 'lib/google/apis/content_v2_1/classes.rb', line 3993

def language
  @language
end

#target_countriesArray<String>

The countries where the items may be displayed. Represented as a CLDR territory code. Will be ignored for "product inventory" feeds. Corresponds to the JSON property targetCountries

Returns:

  • (Array<String>)


3999
4000
4001
# File 'lib/google/apis/content_v2_1/classes.rb', line 3999

def target_countries
  @target_countries
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



4006
4007
4008
4009
4010
4011
4012
4013
# File 'lib/google/apis/content_v2_1/classes.rb', line 4006

def update!(**args)
  @country = args[:country] if args.key?(:country)
  @excluded_destinations = args[:excluded_destinations] if args.key?(:excluded_destinations)
  @feed_label = args[:feed_label] if args.key?(:feed_label)
  @included_destinations = args[:included_destinations] if args.key?(:included_destinations)
  @language = args[:language] if args.key?(:language)
  @target_countries = args[:target_countries] if args.key?(:target_countries)
end