Share via


PackageInstaller.SessionParams Class

Definition

Parameters for creating a new PackageInstaller.Session.

[Android.Runtime.Register("android/content/pm/PackageInstaller$SessionParams", DoNotGenerateAcw=true)]
public class PackageInstaller.SessionParams : Java.Lang.Object, Android.OS.IParcelable, IDisposable, Java.Interop.IJavaPeerable
[<Android.Runtime.Register("android/content/pm/PackageInstaller$SessionParams", DoNotGenerateAcw=true)>]
type PackageInstaller.SessionParams = class
    inherit Object
    interface IParcelable
    interface IJavaObject
    interface IDisposable
    interface IJavaPeerable
Inheritance
PackageInstaller.SessionParams
Attributes
Implements

Remarks

Parameters for creating a new PackageInstaller.Session.

Java documentation for android.content.pm.PackageInstaller.SessionParams.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Constructors

PackageInstaller.SessionParams(IntPtr, JniHandleOwnership)
PackageInstaller.SessionParams(PackageInstallMode)

Construct parameters for a new package install session.

Fields

PermissionStateDefault
Obsolete.

Value is passed by the installer to #setPermissionState(String, int) to set the state of a permission.

PermissionStateDenied
Obsolete.

Value is passed by the installer to #setPermissionState(String, int) to set the state of a permission.

PermissionStateGranted
Obsolete.

Value is passed by the installer to #setPermissionState(String, int) to set the state of a permission.

UserActionNotRequired
Obsolete.

This value is passed by the installer to SessionParams#setRequireUserAction(int) to indicate that user action is not required for this install.

UserActionRequired
Obsolete.

This value is passed by the installer to SessionParams#setRequireUserAction(int) to indicate that user action is required for this install.

UserActionUnspecified
Obsolete.

This value is passed by the installer to SessionParams#setRequireUserAction(int) to indicate that user action is unspecified for this install.

Properties

Class

Returns the runtime class of this Object.

(Inherited from Object)
Creator
Handle

The handle to the underlying Android instance.

(Inherited from Object)
JniIdentityHashCode (Inherited from Object)
JniPeerMembers
PeerReference (Inherited from Object)
RestrictedPermissionsAll

Special constant to refer to all restricted permissions.

ThresholdClass
ThresholdType

Methods

Clone()

Creates and returns a copy of this object.

(Inherited from Object)
DescribeContents()
Dispose() (Inherited from Object)
Dispose(Boolean) (Inherited from Object)
Equals(Object)

Indicates whether some other object is "equal to" this one.

(Inherited from Object)
GetHashCode()

Returns a hash code value for the object.

(Inherited from Object)
JavaFinalize()

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

(Inherited from Object)
Notify()

Wakes up a single thread that is waiting on this object's monitor.

(Inherited from Object)
NotifyAll()

Wakes up all threads that are waiting on this object's monitor.

(Inherited from Object)
SetAppIcon(Bitmap)

Optionally set an icon representing the app being installed.

SetAppLabel(ICharSequence)

Optionally set a label representing the app being installed.

SetAppLabel(String)

Optionally set a label representing the app being installed.

SetApplicationEnabledSettingPersistent()

Request to keep the original application enabled setting.

SetAppPackageName(String)

Optionally set the package name of the app being installed.

SetAutoRevokePermissionsMode(Boolean)

Sets whether permissions should be auto-revoked if this package is unused for an extended periodd of time.

SetDontKillApp(Boolean)

Requests that the system not kill any of the package's running processes as part of a SessionParams#MODE_INHERIT_EXISTING session in which splits being added.

SetHandle(IntPtr, JniHandleOwnership)

Sets the Handle property.

(Inherited from Object)
SetInstallerPackageName(String)

Set the installer package for the app.

SetInstallLocation(PackageInstallLocation)

Provide value of PackageInfo#installLocation, which may be used to determine where the app will be staged.

SetInstallReason(PackageInstallReason)

Set the reason for installing this package.

SetInstallScenario(Int32)

Sets the install scenario for this session, which describes the expected user journey.

SetMultiPackage()

Set this session to be the parent of a multi-package install.

SetOriginatingUid(Int32)

Sets the UID that initiated the package installation.

SetOriginatingUri(Uri)

Optionally set the URI where this package was downloaded from.

SetPackageSource(Int32)

Optionally indicate the package source of the app being installed.

SetPermissionState(String, PackageInstallerPermissionState)
SetReferrerUri(Uri)

Optionally set the URI that referred you to install this package.

SetRequestUpdateOwnership(Boolean)

Optionally indicate whether the package being installed needs the update ownership enforcement.

SetRequireUserAction(Int32)

Optionally indicate whether user action should be required when the session is committed.

SetSize(Int64)

Optionally indicate the total size (in bytes) of all APKs that will be delivered in this session.

SetWhitelistedRestrictedPermissions(ICollection<String>)

Sets which restricted permissions to be allowlisted for the app.

ToArray<T>() (Inherited from Object)
ToString()

Returns a string representation of the object.

(Inherited from Object)
UnregisterFromRuntime() (Inherited from Object)
Wait()

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>.

(Inherited from Object)
Wait(Int64, Int32)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)
Wait(Int64)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)
WriteToParcel(Parcel, ParcelableWriteFlags)

Explicit Interface Implementations

IJavaPeerable.Disposed() (Inherited from Object)
IJavaPeerable.DisposeUnlessReferenced() (Inherited from Object)
IJavaPeerable.Finalized() (Inherited from Object)
IJavaPeerable.JniManagedPeerState (Inherited from Object)
IJavaPeerable.SetJniIdentityHashCode(Int32) (Inherited from Object)
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) (Inherited from Object)
IJavaPeerable.SetPeerReference(JniObjectReference) (Inherited from Object)

Extension Methods

JavaCast<TResult>(IJavaObject)

Performs an Android runtime-checked type conversion.

JavaCast<TResult>(IJavaObject)
GetJniTypeName(IJavaPeerable)

Applies to