Class: Google::Apis::AnalyticsreportingV4::ProductData
- Inherits:
-
Object
- Object
- Google::Apis::AnalyticsreportingV4::ProductData
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/analyticsreporting_v4/classes.rb,
generated/google/apis/analyticsreporting_v4/representations.rb,
generated/google/apis/analyticsreporting_v4/representations.rb
Overview
Details of the products in an e-commerce transaction.
Instance Attribute Summary collapse
-
#item_revenue ⇒ Float
The total revenue from purchased product items.
-
#product_name ⇒ String
The product name, supplied by the e-commerce tracking application, for the purchased items.
-
#product_quantity ⇒ Fixnum
Total number of this product units in the transaction.
-
#product_sku ⇒ String
Unique code that represents the product.
Instance Method Summary collapse
-
#initialize(**args) ⇒ ProductData
constructor
A new instance of ProductData.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ ProductData
Returns a new instance of ProductData.
1176 1177 1178 |
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 1176 def initialize(**args) update!(**args) end |
Instance Attribute Details
#item_revenue ⇒ Float
The total revenue from purchased product items.
Corresponds to the JSON property itemRevenue
1158 1159 1160 |
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 1158 def item_revenue @item_revenue end |
#product_name ⇒ String
The product name, supplied by the e-commerce tracking application, for
the purchased items.
Corresponds to the JSON property productName
1164 1165 1166 |
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 1164 def product_name @product_name end |
#product_quantity ⇒ Fixnum
Total number of this product units in the transaction.
Corresponds to the JSON property productQuantity
1169 1170 1171 |
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 1169 def product_quantity @product_quantity end |
#product_sku ⇒ String
Unique code that represents the product.
Corresponds to the JSON property productSku
1174 1175 1176 |
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 1174 def product_sku @product_sku end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1181 1182 1183 1184 1185 1186 |
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 1181 def update!(**args) @item_revenue = args[:item_revenue] if args.key?(:item_revenue) @product_name = args[:product_name] if args.key?(:product_name) @product_quantity = args[:product_quantity] if args.key?(:product_quantity) @product_sku = args[:product_sku] if args.key?(:product_sku) end |