# ProductEntity

# ProductEntity

*** ** * ** ***

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

<br />

```
class ProductEntity : Entity
```

<br />

|---|---|-----------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [kotlin.Any](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)                                                                                     |||
| ↳ | [com.google.android.engage.common.datamodel.Entity](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Entity)              ||
|   | ↳ | [com.google.android.engage.food.datamodel.ProductEntity](https://developer.android.com/reference/kotlin/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                                                                                                                                     |
|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `class `[ProductEntity.Builder](https://developer.android.com/reference/kotlin/com/google/android/engage/food/datamodel/ProductEntity.Builder) Builder class for[ProductEntity](https://developer.android.com/reference/kotlin/com/google/android/engage/food/datamodel/ProductEntity). |

|                                                                                                                                                           ### Public functions                                                                                                                                                            |
|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Uri](https://developer.android.com/reference/android/net/Uri.html)`!`                                                                                                                                                                                                                                                                    | [getActionLinkUri](https://developer.android.com/reference/kotlin/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://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`!>!`                                                                                                                                                         | [getCallout](https://developer.android.com/reference/kotlin/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://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`!>!`                                                                                                                                                         | [getCalloutFinePrint](https://developer.android.com/reference/kotlin/com/google/android/engage/food/datamodel/ProductEntity#getCalloutFinePrint())`()` Returns the fine print for the callout text e.g. "For a limited time".  |
| `(`[Mutable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-mutable-list/index.html)`)`[List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html)`<`[DisplayTimeWindow](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/DisplayTimeWindow)`!>!` | [getDisplayTimeWindows](https://developer.android.com/reference/kotlin/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://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`!>!`                                                                                                                                                         | [getEntityId](https://developer.android.com/reference/kotlin/com/google/android/engage/food/datamodel/ProductEntity#getEntityId())`()` Returns the id of the entity.                                                           |
| `(`[Mutable](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-mutable-list/index.html)`)`[List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-list/index.html)`<`[Image](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Image)`!>!`                         | [getPosterImages](https://developer.android.com/reference/kotlin/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/kotlin/com/google/android/engage/common/datamodel/Price)`!>!`                                                                                                                                 | [getPrice](https://developer.android.com/reference/kotlin/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/kotlin/com/google/android/engage/common/datamodel/Rating)`!>!`                                                                                                                               | [getRating](https://developer.android.com/reference/kotlin/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://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`!>!`                                                                                                                                                         | [getTitle](https://developer.android.com/reference/kotlin/com/google/android/engage/food/datamodel/ProductEntity#getTitle())`()` Returns the title of the food entity.                                                         |

|                                                                                                                                                                                                                                                                                         ### Inherited functions                                                                                                                                                                                                                                                                                         |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| From[com.google.android.engage.common.datamodel.Entity](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Entity) |----------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------| | [Int](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html) | [getEntityType](https://developer.android.com/reference/kotlin/com/google/android/engage/common/datamodel/Entity#getEntityType())`()` | |

## Public functions

### getActionLinkUri

```
fun getActionLinkUri(): Uri!
```

Returns the action link uri of the food entity.  

### getCallout

```
fun getCallout(): Optional<String!>!
```

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

### getCalloutFinePrint

```
fun getCalloutFinePrint(): Optional<String!>!
```

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

### getDisplayTimeWindows

```
fun getDisplayTimeWindows(): (Mutable)List<DisplayTimeWindow!>!
```

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

```
fun getEntityId(): Optional<String!>!
```

Returns the id of the entity.  

### getPosterImages

```
fun getPosterImages(): (Mutable)List<Image!>!
```

Returns the poster image of the entity.  

### getPrice

```
fun getPrice(): Optional<Price!>!
```

Returns the price of the product entity  

### getRating

```
fun getRating(): Optional<Rating!>!
```

Returns the rating of the food entity.  

### getTitle

```
fun getTitle(): Optional<String!>!
```

Returns the title of the food entity.