# CurrentUserStyleRepository

Artifact: [androidx.wear.watchface:watchface-style](https://developer.android.com/jetpack/androidx/releases/wear-watchface) [View Source](https://cs.android.com/search?q=file:androidx/wear/watchface/style/CurrentUserStyleRepository.kt+class:androidx.wear.watchface.style.CurrentUserStyleRepository) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.0.0) Deprecated in [1.3.0-alpha07](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.3.0-alpha07)

*** ** * ** ***


```
public final class CurrentUserStyleRepository
```

<br />

*** ** * ** ***

> [!CAUTION]
> **This class is deprecated.**   
> AndroidX watchface libraries are deprecated, use Watch Face Format instead. For more info see: https://developer.android.com/training/wearables/wff

In memory storage for the current user style choices represented as a `https://kotlinlang.org/api/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-mutable-state-flow/index.html`\<`https://developer.android.com/reference/androidx/wear/watchface/style/UserStyle`\>.

use Watch Face Format instead

## Summary

| ### Public constructors |
|---|
| `[CurrentUserStyleRepository](https://developer.android.com/reference/androidx/wear/watchface/style/CurrentUserStyleRepository#CurrentUserStyleRepository(androidx.wear.watchface.style.UserStyleSchema))(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/wear/watchface/style/UserStyleSchema schema)` **This method is deprecated.** AndroidX watchface libraries are deprecated, use Watch Face Format instead. |

| ### Public methods |
|---|---|
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/wear/watchface/style/UserStyleSchema` | `[getSchema](https://developer.android.com/reference/androidx/wear/watchface/style/CurrentUserStyleRepository#getSchema())()` **This method is deprecated.** AndroidX watchface libraries are deprecated, use Watch Face Format instead. |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://kotlinlang.org/api/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-state-flow/index.html<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/wear/watchface/style/UserStyle>` | `[getUserStyle](https://developer.android.com/reference/androidx/wear/watchface/style/CurrentUserStyleRepository#getUserStyle())()` **This method is deprecated.** AndroidX watchface libraries are deprecated, use Watch Face Format instead. |

## Public constructors

### CurrentUserStyleRepository

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.0.0) Deprecated in [1.3.0-alpha07](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.3.0-alpha07)

```
public [CurrentUserStyleRepository](https://developer.android.com/reference/androidx/wear/watchface/style/CurrentUserStyleRepository#CurrentUserStyleRepository(androidx.wear.watchface.style.UserStyleSchema))(@NonNull UserStyleSchema schema)
```

> [!CAUTION]
> **This method is deprecated.**   
> AndroidX watchface libraries are deprecated, use Watch Face Format instead. For more info see: https://developer.android.com/training/wearables/wff

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/wear/watchface/style/UserStyleSchema schema` | The `https://developer.android.com/reference/androidx/wear/watchface/style/UserStyleSchema` for this CurrentUserStyleRepository which describes the available style categories. |

## Public methods

### getSchema

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.0.0) Deprecated in [1.3.0-alpha07](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.3.0-alpha07)

```
public final @NonNull UserStyleSchema [getSchema](https://developer.android.com/reference/androidx/wear/watchface/style/CurrentUserStyleRepository#getSchema())()
```

> [!CAUTION]
> **This method is deprecated.**   
> AndroidX watchface libraries are deprecated, use Watch Face Format instead. For more info see: https://developer.android.com/training/wearables/wff

The `https://developer.android.com/reference/androidx/wear/watchface/style/UserStyleSchema` for this CurrentUserStyleRepository which describes the available style categories.

### getUserStyle

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.0.0) Deprecated in [1.3.0-alpha07](https://developer.android.com/jetpack/androidx/releases/wear-watchface#1.3.0-alpha07)

```
public final @NonNull StateFlow<@NonNull UserStyle> [getUserStyle](https://developer.android.com/reference/androidx/wear/watchface/style/CurrentUserStyleRepository#getUserStyle())()
```

> [!CAUTION]
> **This method is deprecated.**   
> AndroidX watchface libraries are deprecated, use Watch Face Format instead. For more info see: https://developer.android.com/training/wearables/wff

The current `https://developer.android.com/reference/androidx/wear/watchface/style/UserStyle`. If accessed from java, consider using androidx.lifecycle.FlowLiveDataConversions.asLiveData to observe changes.