Class: Google::Apis::RetailV2alpha::GoogleCloudRetailV2alphaBranch

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

Overview

A data branch that stores all instances of Products.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudRetailV2alphaBranch

Returns a new instance of GoogleCloudRetailV2alphaBranch.



1722
1723
1724
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 1722

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

Instance Attribute Details

#display_nameString

Output only. Human readable name of the branch to display in the UI. Corresponds to the JSON property displayName

Returns:

  • (String)


1688
1689
1690
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 1688

def display_name
  @display_name
end

#is_defaultBoolean Also known as: is_default?

Output only. Indicates whether this branch is set as the default branch of its parent catalog. Corresponds to the JSON property isDefault

Returns:

  • (Boolean)


1694
1695
1696
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 1694

def is_default
  @is_default
end

#last_product_import_timeString

Output only. Timestamp of last import through ProductService.ImportProducts. Empty value means no import has been made to this branch. Corresponds to the JSON property lastProductImportTime

Returns:

  • (String)


1701
1702
1703
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 1701

def last_product_import_time
  @last_product_import_time
end

#nameString

Immutable. Full resource name of the branch, such as projects/*/locations/ global/catalogs/default_catalog/branches/branch_id. Corresponds to the JSON property name

Returns:

  • (String)


1707
1708
1709
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 1707

def name
  @name
end

#product_count_statsArray<Google::Apis::RetailV2alpha::GoogleCloudRetailV2alphaBranchProductCountStatistic>

Output only. Statistics for number of products in the branch, provided for different scopes. This field is not populated in BranchView.BASIC view. Corresponds to the JSON property productCountStats



1713
1714
1715
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 1713

def product_count_stats
  @product_count_stats
end

#quality_metricsArray<Google::Apis::RetailV2alpha::GoogleCloudRetailV2alphaBranchQualityMetric>

Output only. The quality metrics measured among products of this branch. See QualityMetric.requirement_key for supported metrics. Metrics could be missing if failed to retrieve. This field is not populated in BranchView.BASIC view. Corresponds to the JSON property qualityMetrics



1720
1721
1722
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 1720

def quality_metrics
  @quality_metrics
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1727
1728
1729
1730
1731
1732
1733
1734
# File 'lib/google/apis/retail_v2alpha/classes.rb', line 1727

def update!(**args)
  @display_name = args[:display_name] if args.key?(:display_name)
  @is_default = args[:is_default] if args.key?(:is_default)
  @last_product_import_time = args[:last_product_import_time] if args.key?(:last_product_import_time)
  @name = args[:name] if args.key?(:name)
  @product_count_stats = args[:product_count_stats] if args.key?(:product_count_stats)
  @quality_metrics = args[:quality_metrics] if args.key?(:quality_metrics)
end