Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b47bb25f authored by Bookatz's avatar Bookatz
Browse files

StatsManager: @Deprecated always-deprecated fields

When P shipped, StatsManager had some new (introduced in P) APIs that
were already deprecated but had been needed temporarily. No one should
ever have used these APIs when P shipped because they already had
comments instructing the reader that they were deprecated. They were not
marked @Deprecated, however, so this cl does that.

Fixes: 113856561
Fixes: 77648233
Test: still compiles
Test: make ROBOTEST_FILTER=AnomalyConfigJobServiceTest RunSettingsRoboTests
Test: gts-tradefed run gts-dev --module GtsStatsdHostTestCases
Change-Id: I7c5cdc616f806b9aa5a5e4ee4229750973f533ed
parent b6005f9e
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -119,6 +119,7 @@ public final class StatsManager {
    /**
     * @deprecated Use {@link #addConfig(long, byte[])}
     */
    @Deprecated
    @RequiresPermission(allOf = { DUMP, PACKAGE_USAGE_STATS })
    public boolean addConfiguration(long configKey, byte[] config) {
        try {
@@ -154,6 +155,7 @@ public final class StatsManager {
    /**
     * @deprecated Use {@link #removeConfig(long)}
     */
    @Deprecated
    @RequiresPermission(allOf = { DUMP, PACKAGE_USAGE_STATS })
    public boolean removeConfiguration(long configKey) {
        try {
@@ -222,6 +224,7 @@ public final class StatsManager {
    /**
     * @deprecated Use {@link #setBroadcastSubscriber(PendingIntent, long, long)}
     */
    @Deprecated
    @RequiresPermission(allOf = { DUMP, PACKAGE_USAGE_STATS })
    public boolean setBroadcastSubscriber(
            long configKey, long subscriberId, PendingIntent pendingIntent) {
@@ -275,6 +278,7 @@ public final class StatsManager {
    /**
     * @deprecated Use {@link #setFetchReportsOperation(PendingIntent, long)}
     */
    @Deprecated
    @RequiresPermission(allOf = { DUMP, PACKAGE_USAGE_STATS })
    public boolean setDataFetchOperation(long configKey, PendingIntent pendingIntent) {
        try {
@@ -312,6 +316,7 @@ public final class StatsManager {
    /**
     * @deprecated Use {@link #getReports(long)}
     */
    @Deprecated
    @RequiresPermission(allOf = { DUMP, PACKAGE_USAGE_STATS })
    public @Nullable byte[] getData(long configKey) {
        try {
@@ -348,6 +353,7 @@ public final class StatsManager {
    /**
     * @deprecated Use {@link #getStatsMetadata()}
     */
    @Deprecated
    @RequiresPermission(allOf = { DUMP, PACKAGE_USAGE_STATS })
    public @Nullable byte[] getMetadata() {
        try {