# MediaLibraryInfo

Artifact: [androidx.media3:media3-common](https://developer.android.com/jetpack/androidx/releases/media3) [View Source](https://cs.android.com/search?q=file:androidx/media3/common/MediaLibraryInfo.java+class:androidx.media3.common.MediaLibraryInfo)

*** ** * ** ***


```
@UnstableApi
class MediaLibraryInfo
```

<br />

*** ** * ** ***

Information about the media libraries.

## Summary

| ### Constants |
|---|---|
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#INTERFACE_VERSION() = 10` The version of the interfaces and behaviors offered to other processes. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#TAG() = "AndroidXMedia3"` A tag to use when logging library information. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#TRACE_ENABLED() = true` Whether the library was compiled with `https://developer.android.com/reference/kotlin/androidx/media3/common/util/TraceUtil` trace enabled. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#VERSION() = "1.12.0-alpha02"` The version of the library expressed as a string, for example "1.2.3" or "1.2.0-beta01". |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#VERSION_INT() = 1012000002` The version of the library expressed as an integer, for example 1002003300. |
| `const https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#VERSION_SLASHY() = "AndroidXMedia3/1.12.0-alpha02"` The version of the library expressed as `TAG + "/" + VERSION`. |

| ### Public functions |
|---|---|
| `java-static https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#enableWorkarounds()()` Returns whether device-specific workarounds are enabled. |
| `synchronized java-static https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#registerModule(java.lang.String)(name: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!)` Registers a module to be returned in the `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#registeredModules()` string. |
| `synchronized java-static https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#registeredModules()()` Returns a string consisting of registered module names separated by ", ". |
| `java-static https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `@https://developer.android.com/reference/kotlin/androidx/annotation/VisibleForTesting https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#setEnableWorkarounds(boolean)(enable: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html)` Sets whether device-specific workarounds are enabled. |

## Constants

### INTERFACE_VERSION

```
const val INTERFACE_VERSION = 10: Int
```

The version of the interfaces and behaviors offered to other processes.

This value is monotonically increasing. Its main purpose is to signal which version is running when two versions of the library need to communicate with another across process boundaries. If any cross-process interaction requires an incompatible change, this number should be increased to allow the other process to offer backwards-compatible behavior.

### TAG

```
const val TAG = "AndroidXMedia3": String!
```

A tag to use when logging library information.

### TRACE_ENABLED

```
const val TRACE_ENABLED = true: Boolean
```

Whether the library was compiled with `https://developer.android.com/reference/kotlin/androidx/media3/common/util/TraceUtil` trace enabled.

### VERSION

```
const val VERSION = "1.12.0-alpha02": String!
```

The version of the library expressed as a string, for example "1.2.3" or "1.2.0-beta01".

### VERSION_INT

```
const val VERSION_INT = 1012000002: Int
```

The version of the library expressed as an integer, for example 1002003300.

Three digits are used for each of the first three components of `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#VERSION()`, then a single digit represents the cycle of this version: alpha (0), beta (1), rc (2) or stable (3). Finally two digits are used for the cycle number (always 00 for stable releases).

For example "1.2.0-rc05" has the corresponding integer version 1002000205 (001-002-000-2-05), and "123.45.6" has the corresponding integer version 123045006300 (123-045-006-3-00).

### VERSION_SLASHY

```
const val VERSION_SLASHY = "AndroidXMedia3/1.12.0-alpha02": String!
```

The version of the library expressed as `TAG + "/" + VERSION`.

## Public functions

### enableWorkarounds

```
java-static fun enableWorkarounds(): Boolean
```

Returns whether device-specific workarounds are enabled.

### registerModule

```
synchronized java-static fun registerModule(name: String!): Unit
```

Registers a module to be returned in the `https://developer.android.com/reference/kotlin/androidx/media3/common/MediaLibraryInfo#registeredModules()` string.

| Parameters |
|---|---|
| `name: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | The name of the module being registered. |

### registeredModules

```
synchronized java-static fun registeredModules(): String!
```

Returns a string consisting of registered module names separated by ", ".

### setEnableWorkarounds

```
@VisibleForTesting
java-static fun setEnableWorkarounds(enable: Boolean): Unit
```

Sets whether device-specific workarounds are enabled.

This should only be called for certification testing.