# PaneTemplate

Artifact: [androidx.car.app:app](https://developer.android.com/jetpack/androidx/releases/car-app) [View Source](https://cs.android.com/search?q=file:androidx/car/app/model/PaneTemplate.java+class:androidx.car.app.model.PaneTemplate) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/car-app#1.0.0)

*** ** * ** ***


```
@CarProtocol
class PaneTemplate : Template
```

<br />

*** ** * ** ***

A template that displays a `https://developer.android.com/reference/kotlin/androidx/car/app/model/Pane`.

#### Template Restrictions

In regards to template refreshes, as described in `https://developer.android.com/reference/kotlin/androidx/car/app/Screen#onGetTemplate()`, this template is considered a refresh of a previous one if:

- The previous template is in a loading state (see `https://developer.android.com/reference/kotlin/androidx/car/app/model/Pane.Builder#setLoading(boolean)`, or
- The template title has not changed, and the number of rows and the title (not counting spans) of each row between the previous and new `https://developer.android.com/reference/kotlin/androidx/car/app/model/Pane`s have not changed.

## Summary

| ### Nested types |
|---|
| `class https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate.Builder` A builder of `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate`. |

| ### Public functions |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#equals(java.lang.Object)(other: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html?)` |
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/ActionStrip?` | `[getActionStrip](https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#getActionStrip())()` **This function is deprecated.** use `https://developer.android.com/reference/kotlin/androidx/car/app/model/Header#getEndHeaderActions()` instead. <br /> |
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/Banner?` | `@https://developer.android.com/reference/kotlin/androidx/car/app/annotations/ExperimentalCarApi @https://developer.android.com/reference/kotlin/androidx/car/app/annotations/RequiresCarApi(value = 9) https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#getBanner()()` Returns the `https://developer.android.com/reference/kotlin/androidx/car/app/model/Banner` to display in this template. |
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/Header?` | `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#getHeader()()` Returns the `https://developer.android.com/reference/kotlin/androidx/car/app/model/Header` to display in this template. |
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/Action?` | `[getHeaderAction](https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#getHeaderAction())()` **This function is deprecated.** use `https://developer.android.com/reference/kotlin/androidx/car/app/model/Header#getStartHeaderAction()` instead. <br /> |
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/Pane` | `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#getPane()()` Returns the `https://developer.android.com/reference/kotlin/androidx/car/app/model/Pane` to display in the template. |
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/CarText?` | `[getTitle](https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#getTitle())()` **This function is deprecated.** use `https://developer.android.com/reference/kotlin/androidx/car/app/model/Header#getTitle()` instead. <br /> |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#hashCode()()` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html` | `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#toString()()` |

## Public functions

### equals

```
fun equals(other: Any?): Boolean
```

### getActionStrip

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/car-app#1.0.0) Deprecated in [1.7.0](https://developer.android.com/jetpack/androidx/releases/car-app#1.7.0)

```
fun [getActionStrip](https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#getActionStrip())(): ActionStrip?
```

> [!CAUTION]
> **This function is deprecated.**   
>
> use `https://developer.android.com/reference/kotlin/androidx/car/app/model/Header#getEndHeaderActions()` instead.

Returns the `https://developer.android.com/reference/kotlin/androidx/car/app/model/ActionStrip` for this template or `null` if not set.

| See also |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate.Builder#setActionStrip(androidx.car.app.model.ActionStrip)` |   |

### getBanner

Added in [1.9.0-alpha03](https://developer.android.com/jetpack/androidx/releases/car-app#1.9.0-alpha03)

```
@ExperimentalCarApi
@RequiresCarApi(value = 9)
fun getBanner(): Banner?
```

Returns the `https://developer.android.com/reference/kotlin/androidx/car/app/model/Banner` to display in this template.

| See also |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate.Builder#setBanner(androidx.car.app.model.Banner)` |   |

### getHeader

Added in [1.7.0](https://developer.android.com/jetpack/androidx/releases/car-app#1.7.0)

```
fun getHeader(): Header?
```

Returns the `https://developer.android.com/reference/kotlin/androidx/car/app/model/Header` to display in this template.

This method was introduced in API 7, but is backwards compatible even if the client is using API 6 or below.

| See also |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate.Builder#setHeader(androidx.car.app.model.Header)` |   |

### getHeaderAction

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/car-app#1.0.0) Deprecated in [1.7.0](https://developer.android.com/jetpack/androidx/releases/car-app#1.7.0)

```
fun [getHeaderAction](https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#getHeaderAction())(): Action?
```

> [!CAUTION]
> **This function is deprecated.**   
>
> use `https://developer.android.com/reference/kotlin/androidx/car/app/model/Header#getStartHeaderAction()` instead.

Returns the `https://developer.android.com/reference/kotlin/androidx/car/app/model/Action` that is set to be displayed in the header of the template, or `null` if not set.

| See also |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate.Builder#setHeaderAction(androidx.car.app.model.Action)` |   |

### getPane

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/car-app#1.0.0)

```
fun getPane(): Pane
```

Returns the `https://developer.android.com/reference/kotlin/androidx/car/app/model/Pane` to display in the template.

| See also |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate.Builder#Builder(androidx.car.app.model.Pane)` |   |

### getTitle

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/car-app#1.0.0) Deprecated in [1.7.0](https://developer.android.com/jetpack/androidx/releases/car-app#1.7.0)

```
fun [getTitle](https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate#getTitle())(): CarText?
```

> [!CAUTION]
> **This function is deprecated.**   
>
> use `https://developer.android.com/reference/kotlin/androidx/car/app/model/Header#getTitle()` instead.

Returns the title of the template or `null` if not set.

| See also |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/car/app/model/PaneTemplate.Builder#setTitle(java.lang.CharSequence)` |   |

### hashCode

```
fun hashCode(): Int
```

### toString

```
fun toString(): String
```