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

Commit 605d6b1d authored by Todd Kennedy's avatar Todd Kennedy Committed by Android (Google) Code Review
Browse files

Merge "Return the update timestamp in getStagedSessions()"

parents 088a61fb 56c14ddc
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -11452,6 +11452,7 @@ package android.content.pm {
    method public long getSize();
    method public int getStagedSessionErrorCode();
    method @NonNull public String getStagedSessionErrorMessage();
    method public long getUpdatedMillis();
    method @NonNull public android.os.UserHandle getUser();
    method public boolean isActive();
    method public boolean isCommitted();
+13 −0
Original line number Diff line number Diff line
@@ -17,6 +17,7 @@
package android.content.pm;

import android.Manifest;
import android.annotation.CurrentTimeMillisLong;
import android.annotation.IntDef;
import android.annotation.NonNull;
import android.annotation.Nullable;
@@ -1816,6 +1817,9 @@ public class PackageInstaller {
        /** {@hide} */
        public boolean isCommitted;

        /** {@hide} */
        public long updatedMillis;

        /** {@hide} */
        @UnsupportedAppUsage
        public SessionInfo() {
@@ -2237,6 +2241,15 @@ public class PackageInstaller {
            return isCommitted;
        }

        /**
         * The timestamp of the last update that occurred to the session, including changing of
         * states in case of staged sessions.
         */
        @CurrentTimeMillisLong
        public long getUpdatedMillis() {
            return updatedMillis;
        }

        @Override
        public int describeContents() {
            return 0;
+1 −0
Original line number Diff line number Diff line
@@ -498,6 +498,7 @@ public class PackageInstallerSession extends IPackageInstallerSession.Stub {
            info.isStagedSessionReady = mStagedSessionReady;
            info.isStagedSessionFailed = mStagedSessionFailed;
            info.setStagedSessionErrorCode(mStagedSessionErrorCode, mStagedSessionErrorMessage);
            info.updatedMillis = updatedMillis;
        }
        return info;
    }