public final class UserEvent extends GeneratedMessageV3 implements UserEventOrBuilder
UserEvent captures all metadata information recommendation engine needs to
know about how end users interact with customers' website.
Protobuf type google.cloud.recommendationengine.v1beta1.UserEvent
Inherited Members
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessageV3.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)
Static Fields
EVENT_DETAIL_FIELD_NUMBER
public static final int EVENT_DETAIL_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
EVENT_SOURCE_FIELD_NUMBER
public static final int EVENT_SOURCE_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
EVENT_TIME_FIELD_NUMBER
public static final int EVENT_TIME_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
EVENT_TYPE_FIELD_NUMBER
public static final int EVENT_TYPE_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
PRODUCT_EVENT_DETAIL_FIELD_NUMBER
public static final int PRODUCT_EVENT_DETAIL_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
USER_INFO_FIELD_NUMBER
public static final int USER_INFO_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
Static Methods
getDefaultInstance()
public static UserEvent getDefaultInstance()
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
newBuilder()
public static UserEvent.Builder newBuilder()
newBuilder(UserEvent prototype)
public static UserEvent.Builder newBuilder(UserEvent prototype)
public static UserEvent parseDelimitedFrom(InputStream input)
public static UserEvent parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(byte[] data)
public static UserEvent parseFrom(byte[] data)
Parameter |
---|
Name | Description |
data | byte[]
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static UserEvent parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteString data)
public static UserEvent parseFrom(ByteString data)
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static UserEvent parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static UserEvent parseFrom(CodedInputStream input)
public static UserEvent parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static UserEvent parseFrom(InputStream input)
public static UserEvent parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteBuffer data)
public static UserEvent parseFrom(ByteBuffer data)
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static UserEvent parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
parser()
public static Parser<UserEvent> parser()
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter |
---|
Name | Description |
obj | Object
|
Overrides
getDefaultInstanceForType()
public UserEvent getDefaultInstanceForType()
getEventDetail()
public EventDetail getEventDetail()
Optional. User event detailed information common across different
recommendation types.
.google.cloud.recommendationengine.v1beta1.EventDetail event_detail = 3 [(.google.api.field_behavior) = OPTIONAL];
getEventDetailOrBuilder()
public EventDetailOrBuilder getEventDetailOrBuilder()
Optional. User event detailed information common across different
recommendation types.
.google.cloud.recommendationengine.v1beta1.EventDetail event_detail = 3 [(.google.api.field_behavior) = OPTIONAL];
getEventSource()
public UserEvent.EventSource getEventSource()
Optional. This field should not be set when using JavaScript pixel
or the Recommendations AI Tag. Defaults to EVENT_SOURCE_UNSPECIFIED
.
.google.cloud.recommendationengine.v1beta1.UserEvent.EventSource event_source = 6 [(.google.api.field_behavior) = OPTIONAL];
getEventSourceValue()
public int getEventSourceValue()
Optional. This field should not be set when using JavaScript pixel
or the Recommendations AI Tag. Defaults to EVENT_SOURCE_UNSPECIFIED
.
.google.cloud.recommendationengine.v1beta1.UserEvent.EventSource event_source = 6 [(.google.api.field_behavior) = OPTIONAL];
Returns |
---|
Type | Description |
int | The enum numeric value on the wire for eventSource.
|
getEventTime()
public Timestamp getEventTime()
Optional. Only required for ImportUserEvents method. Timestamp of user
event created.
.google.protobuf.Timestamp event_time = 5 [(.google.api.field_behavior) = OPTIONAL];
Returns |
---|
Type | Description |
Timestamp | The eventTime.
|
getEventTimeOrBuilder()
public TimestampOrBuilder getEventTimeOrBuilder()
Optional. Only required for ImportUserEvents method. Timestamp of user
event created.
.google.protobuf.Timestamp event_time = 5 [(.google.api.field_behavior) = OPTIONAL];
getEventType()
public String getEventType()
Required. User event type. Allowed values are:
add-to-cart
Products being added to cart.
add-to-list
Items being added to a list (shopping list, favorites
etc).
category-page-view
Special pages such as sale or promotion pages
viewed.
checkout-start
User starting a checkout process.
detail-page-view
Products detail page viewed.
home-page-view
Homepage viewed.
page-visit
Generic page visits not included in the event types above.
purchase-complete
User finishing a purchase.
refund
Purchased items being refunded or returned.
remove-from-cart
Products being removed from cart.
remove-from-list
Items being removed from a list.
search
Product search.
shopping-cart-page-view
User viewing a shopping cart.
impression
List of items displayed. Used by Google Tag Manager.
string event_type = 1 [(.google.api.field_behavior) = REQUIRED];
Returns |
---|
Type | Description |
String | The eventType.
|
getEventTypeBytes()
public ByteString getEventTypeBytes()
Required. User event type. Allowed values are:
add-to-cart
Products being added to cart.
add-to-list
Items being added to a list (shopping list, favorites
etc).
category-page-view
Special pages such as sale or promotion pages
viewed.
checkout-start
User starting a checkout process.
detail-page-view
Products detail page viewed.
home-page-view
Homepage viewed.
page-visit
Generic page visits not included in the event types above.
purchase-complete
User finishing a purchase.
refund
Purchased items being refunded or returned.
remove-from-cart
Products being removed from cart.
remove-from-list
Items being removed from a list.
search
Product search.
shopping-cart-page-view
User viewing a shopping cart.
impression
List of items displayed. Used by Google Tag Manager.
string event_type = 1 [(.google.api.field_behavior) = REQUIRED];
Returns |
---|
Type | Description |
ByteString | The bytes for eventType.
|
getParserForType()
public Parser<UserEvent> getParserForType()
Overrides
getProductEventDetail()
public ProductEventDetail getProductEventDetail()
Optional. Retail product specific user event metadata.
This field is required for the following event types:
add-to-cart
add-to-list
category-page-view
checkout-start
detail-page-view
purchase-complete
refund
remove-from-cart
remove-from-list
search
This field is optional for the following event types:
page-visit
shopping-cart-page-view
- note that 'product_event_detail' should be
set for this unless the shopping cart is empty.
This field is not allowed for the following event types:
home-page-view
.google.cloud.recommendationengine.v1beta1.ProductEventDetail product_event_detail = 4 [(.google.api.field_behavior) = OPTIONAL];
getProductEventDetailOrBuilder()
public ProductEventDetailOrBuilder getProductEventDetailOrBuilder()
Optional. Retail product specific user event metadata.
This field is required for the following event types:
add-to-cart
add-to-list
category-page-view
checkout-start
detail-page-view
purchase-complete
refund
remove-from-cart
remove-from-list
search
This field is optional for the following event types:
page-visit
shopping-cart-page-view
- note that 'product_event_detail' should be
set for this unless the shopping cart is empty.
This field is not allowed for the following event types:
home-page-view
.google.cloud.recommendationengine.v1beta1.ProductEventDetail product_event_detail = 4 [(.google.api.field_behavior) = OPTIONAL];
getSerializedSize()
public int getSerializedSize()
Returns |
---|
Type | Description |
int | |
Overrides
getUserInfo()
public UserInfo getUserInfo()
Required. User information.
.google.cloud.recommendationengine.v1beta1.UserInfo user_info = 2 [(.google.api.field_behavior) = REQUIRED];
Returns |
---|
Type | Description |
UserInfo | The userInfo.
|
getUserInfoOrBuilder()
public UserInfoOrBuilder getUserInfoOrBuilder()
Required. User information.
.google.cloud.recommendationengine.v1beta1.UserInfo user_info = 2 [(.google.api.field_behavior) = REQUIRED];
hasEventDetail()
public boolean hasEventDetail()
Optional. User event detailed information common across different
recommendation types.
.google.cloud.recommendationengine.v1beta1.EventDetail event_detail = 3 [(.google.api.field_behavior) = OPTIONAL];
Returns |
---|
Type | Description |
boolean | Whether the eventDetail field is set.
|
hasEventTime()
public boolean hasEventTime()
Optional. Only required for ImportUserEvents method. Timestamp of user
event created.
.google.protobuf.Timestamp event_time = 5 [(.google.api.field_behavior) = OPTIONAL];
Returns |
---|
Type | Description |
boolean | Whether the eventTime field is set.
|
hasProductEventDetail()
public boolean hasProductEventDetail()
Optional. Retail product specific user event metadata.
This field is required for the following event types:
add-to-cart
add-to-list
category-page-view
checkout-start
detail-page-view
purchase-complete
refund
remove-from-cart
remove-from-list
search
This field is optional for the following event types:
page-visit
shopping-cart-page-view
- note that 'product_event_detail' should be
set for this unless the shopping cart is empty.
This field is not allowed for the following event types:
home-page-view
.google.cloud.recommendationengine.v1beta1.ProductEventDetail product_event_detail = 4 [(.google.api.field_behavior) = OPTIONAL];
Returns |
---|
Type | Description |
boolean | Whether the productEventDetail field is set.
|
hasUserInfo()
public boolean hasUserInfo()
Required. User information.
.google.cloud.recommendationengine.v1beta1.UserInfo user_info = 2 [(.google.api.field_behavior) = REQUIRED];
Returns |
---|
Type | Description |
boolean | Whether the userInfo field is set.
|
hashCode()
Returns |
---|
Type | Description |
int | |
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
newBuilderForType()
public UserEvent.Builder newBuilderForType()
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected UserEvent.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Overrides
toBuilder()
public UserEvent.Builder toBuilder()
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Overrides