Struct googapis::google::cloud::recommendationengine::v1beta1::ProductEventDetail [−][src]
pub struct ProductEventDetail {
pub search_query: String,
pub page_categories: Vec<CategoryHierarchy>,
pub product_details: Vec<ProductDetail>,
pub list_id: String,
pub cart_id: String,
pub purchase_transaction: Option<PurchaseTransaction>,
}
Expand description
ProductEventDetail captures user event information specific to retail products.
Fields
search_query: String
Required for search
events. Other event types should not set this field.
The user’s search query as UTF-8 encoded text with a length limit of 5 KiB.
page_categories: Vec<CategoryHierarchy>
Required for category-page-view
events. Other event types should not set
this field.
The categories associated with a category page.
Category pages include special pages such as sales or promotions. For
instance, a special sale page may have the category hierarchy:
categories : [“Sales”, “2017 Black Friday Deals”].
product_details: Vec<ProductDetail>
The main product details related to the event.
This field is required for the following event types:
add-to-cart
add-to-list
checkout-start
detail-page-view
purchase-complete
refund
remove-from-cart
remove-from-list
This field is optional for the following event types:
page-visit
shopping-cart-page-view
- note that ‘product_details’ should be set for this unless the shopping cart is empty.
This field is not allowed for the following event types:
category-page-view
home-page-view
search
list_id: String
Required for add-to-list
and remove-from-list
events. The id or name of
the list that the item is being added to or removed from. Other event types
should not set this field.
cart_id: String
Optional. The id or name of the associated shopping cart. This id is used to associate multiple items added or present in the cart before purchase.
This can only be set for add-to-cart
, remove-from-cart
,
checkout-start
, purchase-complete
, or shopping-cart-page-view
events.
purchase_transaction: Option<PurchaseTransaction>
Optional. A transaction represents the entire purchase transaction.
Required for purchase-complete
events. Optional for checkout-start
events. Other event types should not set this field.
Trait Implementations
fn merge_field<B>(
&mut self,
tag: u32,
wire_type: WireType,
buf: &mut B,
ctx: DecodeContext
) -> Result<(), DecodeError> where
B: Buf,
Returns the encoded length of the message without a length delimiter.
Encodes the message to a buffer. Read more
Encodes the message to a newly allocated buffer.
Encodes the message with a length-delimiter to a buffer. Read more
Encodes the message with a length-delimiter to a newly allocated buffer.
Decodes an instance of the message from a buffer. Read more
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError> where
Self: Default,
B: Buf,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError> where
Self: Default,
B: Buf,
Decodes a length-delimited instance of the message from the buffer.
Decodes an instance of the message from a buffer, and merges it into self
. Read more
Decodes a length-delimited instance of the message from buffer, and
merges it into self
. Read more
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl RefUnwindSafe for ProductEventDetail
impl Send for ProductEventDetail
impl Sync for ProductEventDetail
impl Unpin for ProductEventDetail
impl UnwindSafe for ProductEventDetail
Blanket Implementations
Mutably borrows from an owned value. Read more
Wrap the input message T
in a tonic::Request
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more