
This imports all the classes and resources needed by our code. We still have the nominal dependency on the artifact as we need to access the Parcelable CREATORs of MediaSessionCompat.Token, MediaDescriptionCompat, RatingCompat and MediaBrowserCompat.MediaItem. Mechanical import steps: - Put all files under a new 'legacy' package and change all import statements accordingly. - Reformat to adhere to Media3 java style guide - Remove all existing @RestrictTo annotations and replace them with top-level @RestrictTo(LIBRARY) on all classes in the new package. - Remove @NonNull annotations and fixed nullability test errors - Fix HTML javadoc build errors - Fix Lint errors (but not warnings) The code still contains many lint warnings that will be fixed separately. PiperOrigin-RevId: 627999285
Session module
This module provides media session functionality through which media information and controls can be exposed to the Android platform, as well as to other processes and applications.
Getting the module
The easiest way to get the module is to add it as a gradle dependency:
implementation 'androidx.media3:media3-session:1.X.X'
where 1.X.X
is the version, which must match the version of the other media
modules being used.
Alternatively, you can clone this GitHub project and depend on the module locally. Instructions for doing this can be found in the top level README.