Loading core/api/current.txt +1 −2 Original line number Diff line number Diff line Loading @@ -24614,7 +24614,6 @@ package android.media.effect { package android.media.metrics { public abstract class Event { ctor protected Event(long); method @NonNull public android.os.Bundle getMetricsBundle(); method @IntRange(from=0xffffffff) public long getTimeSinceCreatedMillis(); } Loading @@ -24624,7 +24623,7 @@ package android.media.metrics { field @NonNull public static final android.media.metrics.LogSessionId LOG_SESSION_ID_NONE; } public class MediaMetricsManager { public final class MediaMetricsManager { method @NonNull public android.media.metrics.PlaybackSession createPlaybackSession(); method @NonNull public android.media.metrics.RecordingSession createRecordingSession(); field public static final long INVALID_TIMESTAMP = -1L; // 0xffffffffffffffffL media/java/android/media/metrics/Event.java +4 −6 Original line number Diff line number Diff line Loading @@ -32,19 +32,17 @@ public abstract class Event { mTimeSinceCreatedMillis = MediaMetricsManager.INVALID_TIMESTAMP; } // TODO: remove protected Event(long timeSinceCreatedMillis) { mTimeSinceCreatedMillis = timeSinceCreatedMillis; } /* package */ Event(long timeSinceCreatedMillis, Bundle extras) { mTimeSinceCreatedMillis = timeSinceCreatedMillis; mMetricsBundle = extras; } /** * Gets time since the corresponding instance is created in millisecond. * Gets time since the corresponding log session is created in millisecond. * @return the timestamp since the instance is created, or -1 if unknown. * @see LogSessionId * @see PlaybackSession * @see RecordingSession */ @IntRange(from = -1) public long getTimeSinceCreatedMillis() { Loading media/java/android/media/metrics/MediaMetricsManager.java +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ import android.os.RemoteException; * This class gives information about, and interacts with media metrics. */ @SystemService(Context.MEDIA_METRICS_SERVICE) public class MediaMetricsManager { public final class MediaMetricsManager { public static final long INVALID_TIMESTAMP = -1; private static final String TAG = "MediaMetricsManager"; Loading media/java/android/media/metrics/NetworkEvent.java +7 −6 Original line number Diff line number Diff line Loading @@ -105,10 +105,8 @@ public final class NetworkEvent extends Event implements Parcelable { /** * Creates a new NetworkEvent. * * @hide */ public NetworkEvent(@NetworkType int type, long timeSinceCreatedMillis, private NetworkEvent(@NetworkType int type, long timeSinceCreatedMillis, @NonNull Bundle extras) { this.mNetworkType = type; this.mTimeSinceCreatedMillis = timeSinceCreatedMillis; Loading @@ -124,8 +122,11 @@ public final class NetworkEvent extends Event implements Parcelable { } /** * Gets timestamp since the creation in milliseconds. * Gets timestamp since the creation of the log session in milliseconds. * @return the timestamp since the creation in milliseconds, or -1 if unknown. * @see LogSessionId * @see PlaybackSession * @see RecordingSession */ @Override @IntRange(from = -1) Loading Loading @@ -177,8 +178,7 @@ public final class NetworkEvent extends Event implements Parcelable { return 0; } /** @hide */ /* package-private */ NetworkEvent(@NonNull android.os.Parcel in) { private NetworkEvent(@NonNull android.os.Parcel in) { int type = in.readInt(); long timeSinceCreatedMillis = in.readLong(); Bundle extras = in.readBundle(); Loading Loading @@ -230,6 +230,7 @@ public final class NetworkEvent extends Event implements Parcelable { * Sets timestamp since the creation in milliseconds. * @param value the timestamp since the creation in milliseconds. * -1 indicates the value is unknown. * @see #getTimeSinceCreatedMillis() */ public @NonNull Builder setTimeSinceCreatedMillis(@IntRange(from = -1) long value) { mTimeSinceCreatedMillis = value; Loading media/java/android/media/metrics/PlaybackErrorEvent.java +6 −6 Original line number Diff line number Diff line Loading @@ -150,10 +150,8 @@ public final class PlaybackErrorEvent extends Event implements Parcelable { /** * Creates a new PlaybackErrorEvent. * * @hide */ public PlaybackErrorEvent( private PlaybackErrorEvent( @Nullable String exceptionStack, int errorCode, int subErrorCode, Loading Loading @@ -191,8 +189,10 @@ public final class PlaybackErrorEvent extends Event implements Parcelable { } /** * Gets the timestamp since creation in milliseconds. * Gets the timestamp since creation of the playback session in milliseconds. * @return the timestamp since the playback is created, or -1 if unknown. * @see LogSessionId * @see PlaybackSession */ @Override @IntRange(from = -1) Loading Loading @@ -254,8 +254,7 @@ public final class PlaybackErrorEvent extends Event implements Parcelable { return 0; } /** @hide */ /* package-private */ PlaybackErrorEvent(@NonNull Parcel in) { private PlaybackErrorEvent(@NonNull Parcel in) { byte flg = in.readByte(); String exceptionStack = (flg & 0x1) == 0 ? null : in.readString(); int errorCode = in.readInt(); Loading Loading @@ -330,6 +329,7 @@ public final class PlaybackErrorEvent extends Event implements Parcelable { * Set the timestamp since creation in milliseconds. * @param value the timestamp since the creation in milliseconds. * -1 indicates the value is unknown. * @see #getTimeSinceCreatedMillis() */ public @NonNull Builder setTimeSinceCreatedMillis(@IntRange(from = -1) long value) { mTimeSinceCreatedMillis = value; Loading Loading
core/api/current.txt +1 −2 Original line number Diff line number Diff line Loading @@ -24614,7 +24614,6 @@ package android.media.effect { package android.media.metrics { public abstract class Event { ctor protected Event(long); method @NonNull public android.os.Bundle getMetricsBundle(); method @IntRange(from=0xffffffff) public long getTimeSinceCreatedMillis(); } Loading @@ -24624,7 +24623,7 @@ package android.media.metrics { field @NonNull public static final android.media.metrics.LogSessionId LOG_SESSION_ID_NONE; } public class MediaMetricsManager { public final class MediaMetricsManager { method @NonNull public android.media.metrics.PlaybackSession createPlaybackSession(); method @NonNull public android.media.metrics.RecordingSession createRecordingSession(); field public static final long INVALID_TIMESTAMP = -1L; // 0xffffffffffffffffL
media/java/android/media/metrics/Event.java +4 −6 Original line number Diff line number Diff line Loading @@ -32,19 +32,17 @@ public abstract class Event { mTimeSinceCreatedMillis = MediaMetricsManager.INVALID_TIMESTAMP; } // TODO: remove protected Event(long timeSinceCreatedMillis) { mTimeSinceCreatedMillis = timeSinceCreatedMillis; } /* package */ Event(long timeSinceCreatedMillis, Bundle extras) { mTimeSinceCreatedMillis = timeSinceCreatedMillis; mMetricsBundle = extras; } /** * Gets time since the corresponding instance is created in millisecond. * Gets time since the corresponding log session is created in millisecond. * @return the timestamp since the instance is created, or -1 if unknown. * @see LogSessionId * @see PlaybackSession * @see RecordingSession */ @IntRange(from = -1) public long getTimeSinceCreatedMillis() { Loading
media/java/android/media/metrics/MediaMetricsManager.java +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ import android.os.RemoteException; * This class gives information about, and interacts with media metrics. */ @SystemService(Context.MEDIA_METRICS_SERVICE) public class MediaMetricsManager { public final class MediaMetricsManager { public static final long INVALID_TIMESTAMP = -1; private static final String TAG = "MediaMetricsManager"; Loading
media/java/android/media/metrics/NetworkEvent.java +7 −6 Original line number Diff line number Diff line Loading @@ -105,10 +105,8 @@ public final class NetworkEvent extends Event implements Parcelable { /** * Creates a new NetworkEvent. * * @hide */ public NetworkEvent(@NetworkType int type, long timeSinceCreatedMillis, private NetworkEvent(@NetworkType int type, long timeSinceCreatedMillis, @NonNull Bundle extras) { this.mNetworkType = type; this.mTimeSinceCreatedMillis = timeSinceCreatedMillis; Loading @@ -124,8 +122,11 @@ public final class NetworkEvent extends Event implements Parcelable { } /** * Gets timestamp since the creation in milliseconds. * Gets timestamp since the creation of the log session in milliseconds. * @return the timestamp since the creation in milliseconds, or -1 if unknown. * @see LogSessionId * @see PlaybackSession * @see RecordingSession */ @Override @IntRange(from = -1) Loading Loading @@ -177,8 +178,7 @@ public final class NetworkEvent extends Event implements Parcelable { return 0; } /** @hide */ /* package-private */ NetworkEvent(@NonNull android.os.Parcel in) { private NetworkEvent(@NonNull android.os.Parcel in) { int type = in.readInt(); long timeSinceCreatedMillis = in.readLong(); Bundle extras = in.readBundle(); Loading Loading @@ -230,6 +230,7 @@ public final class NetworkEvent extends Event implements Parcelable { * Sets timestamp since the creation in milliseconds. * @param value the timestamp since the creation in milliseconds. * -1 indicates the value is unknown. * @see #getTimeSinceCreatedMillis() */ public @NonNull Builder setTimeSinceCreatedMillis(@IntRange(from = -1) long value) { mTimeSinceCreatedMillis = value; Loading
media/java/android/media/metrics/PlaybackErrorEvent.java +6 −6 Original line number Diff line number Diff line Loading @@ -150,10 +150,8 @@ public final class PlaybackErrorEvent extends Event implements Parcelable { /** * Creates a new PlaybackErrorEvent. * * @hide */ public PlaybackErrorEvent( private PlaybackErrorEvent( @Nullable String exceptionStack, int errorCode, int subErrorCode, Loading Loading @@ -191,8 +189,10 @@ public final class PlaybackErrorEvent extends Event implements Parcelable { } /** * Gets the timestamp since creation in milliseconds. * Gets the timestamp since creation of the playback session in milliseconds. * @return the timestamp since the playback is created, or -1 if unknown. * @see LogSessionId * @see PlaybackSession */ @Override @IntRange(from = -1) Loading Loading @@ -254,8 +254,7 @@ public final class PlaybackErrorEvent extends Event implements Parcelable { return 0; } /** @hide */ /* package-private */ PlaybackErrorEvent(@NonNull Parcel in) { private PlaybackErrorEvent(@NonNull Parcel in) { byte flg = in.readByte(); String exceptionStack = (flg & 0x1) == 0 ? null : in.readString(); int errorCode = in.readInt(); Loading Loading @@ -330,6 +329,7 @@ public final class PlaybackErrorEvent extends Event implements Parcelable { * Set the timestamp since creation in milliseconds. * @param value the timestamp since the creation in milliseconds. * -1 indicates the value is unknown. * @see #getTimeSinceCreatedMillis() */ public @NonNull Builder setTimeSinceCreatedMillis(@IntRange(from = -1) long value) { mTimeSinceCreatedMillis = value; Loading