# ProductEntity

# ProductEntity

*** ** * ** ***

[Kotlin](https://developer.android.com/reference/kotlin/com/google/android/engage/food/datamodel/ProductEntity "View this page in Kotlin")\|Java  

<br />

```
public final class ProductEntity extends Entity
```

<br />

|---|---|----------------------------------------------------------------------------------------------------------------------------------------------------------|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object.html)                                                                              |||
| ↳ | [com.google.android.engage.common.datamodel.Entity](https://developer.android.com/reference/com/google/android/engage/common/datamodel/Entity)              ||
|   | ↳ | [com.google.android.engage.food.datamodel.ProductEntity](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity) |

*** ** * ** ***

An object representing a product entity. (e.g. grocery item, dish from a restaurant, promotion)

## Summary

|                                                                                                                                    ### Nested types                                                                                                                                    |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `public final class `[ProductEntity.Builder](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity.Builder) Builder class for[ProductEntity](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity). |

|                                                                                         ### Public methods                                                                                         |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Uri](https://developer.android.com/reference/android/net/Uri.html)                                                                                                                                | [getActionLinkUri](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity#getActionLinkUri())`()` Returns the action link uri of the food entity.                               |
| [Optional](https://guava.dev/releases/21.0/api/docs/com/google/common/base/Optional.html)`<`[String](https://developer.android.com/reference/java/lang/String.html)`>`                             | [getCallout](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity#getCallout())`()` Returns the callout of the product entity. e.g. "Free delivery"                           |
| [Optional](https://guava.dev/releases/21.0/api/docs/com/google/common/base/Optional.html)`<`[String](https://developer.android.com/reference/java/lang/String.html)`>`                             | [getCalloutFinePrint](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity#getCalloutFinePrint())`()` Returns the fine print for the callout text e.g. "For a limited time".  |
| [List](https://developer.android.com/reference/java/util/List.html)`<`[DisplayTimeWindow](https://developer.android.com/reference/com/google/android/engage/common/datamodel/DisplayTimeWindow)`>` | [getDisplayTimeWindows](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity#getDisplayTimeWindows())`()` Returns the display time window associated with the product entity. |
| [Optional](https://guava.dev/releases/21.0/api/docs/com/google/common/base/Optional.html)`<`[String](https://developer.android.com/reference/java/lang/String.html)`>`                             | [getEntityId](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity#getEntityId())`()` Returns the id of the entity.                                                           |
| [List](https://developer.android.com/reference/java/util/List.html)`<`[Image](https://developer.android.com/reference/com/google/android/engage/common/datamodel/Image)`>`                         | [getPosterImages](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity#getPosterImages())`()` Returns the poster image of the entity.                                         |
| [Optional](https://guava.dev/releases/21.0/api/docs/com/google/common/base/Optional.html)`<`[Price](https://developer.android.com/reference/com/google/android/engage/common/datamodel/Price)`>`   | [getPrice](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity#getPrice())`()` Returns the price of the product entity                                                       |
| [Optional](https://guava.dev/releases/21.0/api/docs/com/google/common/base/Optional.html)`<`[Rating](https://developer.android.com/reference/com/google/android/engage/common/datamodel/Rating)`>` | [getRating](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity#getRating())`()` Returns the rating of the food entity.                                                      |
| [Optional](https://guava.dev/releases/21.0/api/docs/com/google/common/base/Optional.html)`<`[String](https://developer.android.com/reference/java/lang/String.html)`>`                             | [getTitle](https://developer.android.com/reference/com/google/android/engage/food/datamodel/ProductEntity#getTitle())`()` Returns the title of the food entity.                                                         |

|                                                                                                                                                                                                          ### Inherited methods                                                                                                                                                                                                           |
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| From[com.google.android.engage.common.datamodel.Entity](https://developer.android.com/reference/com/google/android/engage/common/datamodel/Entity) |-------|--------------------------------------------------------------------------------------------------------------------------------| | `int` | [getEntityType](https://developer.android.com/reference/com/google/android/engage/common/datamodel/Entity#getEntityType())`()` | |

## Public methods

### getActionLinkUri

```
public Uri getActionLinkUri()
```

Returns the action link uri of the food entity.  

### getCallout

```
public Optional<String> getCallout()
```

Returns the callout of the product entity. e.g. "Free delivery"  

### getCalloutFinePrint

```
public Optional<String> getCalloutFinePrint()
```

Returns the fine print for the callout text e.g. "For a limited time".  

### getDisplayTimeWindows

```
public List<DisplayTimeWindow> getDisplayTimeWindows()
```

Returns the display time window associated with the product entity.

This can be used for several usecases like offer expiry time window, preorder availability time window.  

### getEntityId

```
public Optional<String> getEntityId()
```

Returns the id of the entity.  

### getPosterImages

```
public List<Image> getPosterImages()
```

Returns the poster image of the entity.  

### getPrice

```
public Optional<Price> getPrice()
```

Returns the price of the product entity  

### getRating

```
public Optional<Rating> getRating()
```

Returns the rating of the food entity.  

### getTitle

```
public Optional<String> getTitle()
```

Returns the title of the food entity.