PackageObject QML Type

The handle for a package known to the application manager. More...

Import Statement: import QtApplicationManager.SystemUI 2.0

Properties

Detailed Description

Each instance of this class represents a single package known to the application manager.

Most of the read-only properties map directly to values read from the package's info.yaml file - these are documented in the Manifest Definition.

Items of this type are not creatable from QML code. Only functions and properties of PackageManager will return pointers to this class.

Make sure to not save references to a PackageObject across function calls: packages can be deinstalled at any time, invalidating your reference. In case you do need a persistent handle, use the id string.

Property Documentation

applications : list<ApplicationObject> [read-only]

Returns a list of ApplicationObjects that are part of this package.


blocked : bool [read-only]

Describes if this package is currently blocked: being blocked means that all applications in the package are stopped and are prevented from being started while in this state. This is normally only the case while an update is being applied.


builtIn : bool [read-only]

This property describes, if this package is part of the built-in set of packages of the current System UI.


builtInHasRemovableUpdate : bool [read-only]

This property describes, if this package is part of the built-in set of packages of the current System UI and if there is currently an update installed that shadows the original built-in package contents.

See also builtIn.


categories : list<string> [read-only]

A list of category names the package should be associated with. This is mainly for the automated app-store uploads as well as displaying the package within a fixed set of categories in the System UI.


description : string [read-only]

Returns the localized description of the package - as provided in the info.yaml file - in the currently active locale.

This property uses the same algorithm as the name property, but for the description.


descriptions : var [read-only]

Returns an object with all the language code to localized description mappings as provided in the package's info.yaml file.


icon : url [read-only]

The URL of the package's icon - can be used as the source property of an Image.


id : string [read-only]

This property returns the unique id of the package.


name : string [read-only]

Returns the localized name of the package - as provided in the info.yaml file - in the currently active locale.

This is a convenience property, that takes the mapping returned by the names property, and then tries to return the value for these keys if available: first the current locale's id, then en_US, then en and lastly the first available key.

If no mapping is available, this will return the id.


names : var [read-only]

Returns an object with all the language code to localized name mappings as provided in the package's info.yaml file.


state : enumeration [read-only]

This property holds the current installation state of the package. It can be one of:

  • PackageObject.Installed - The package is completely installed and ready to be used.
  • PackageObject.BeingInstalled - The package is currently in the process of being installed.
  • PackageObject.BeingUpdated - The package is currently in the process of being updated.
  • PackageObject.BeingDowngraded - The package is currently in the process of being downgraded. That can only happen for a built-in package that was previously upgraded. It will then be brought back to its original, built-in, version and its state will go back to PackageObject.Installed.
  • PackageObject.BeingRemoved - The package is currently in the process of being removed.

version : string [read-only]

Holds the version of the package as a string.


© 2023 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.