History log of /haiku/headers/os/package/PackageRoster.h
Revision Date Author Comments
# b711002d 07-Aug-2019 Ryan Leavengood <leavengood@gmail.com>

HaikuDepot: Set package state when loading single package

Without this, even installed packages still get an "Install" button.

Fixes #14821.

This was implemented by adding BPackageRoster::IsPackageActive. I decided to
have this take a location since GetActivePackages also did, but as noted in my
TODO comment, I think this is awkward.

It would also be nice to show the user they have a different version of a
particular package, but that would require some changes to IsPackageActive.

Change-Id: Iab0d35eb6b671a17711b0214b15164d296927e5a
Reviewed-on: https://review.haiku-os.org/c/1694
Reviewed-by: Stephan Aßmus <superstippi@gmx.de>


# e2c7bb90 01-Mar-2019 CodeforEvolution <secundaja@gmail.com>

Add Reboot Check to BPackageRoster

A bit of an explanation for these weirdly named functions:
LatestActivePackageInfos() returns the packages on the system that are
both installed and fully set up. When packages are in the middle of being
installed, LatestInactivePackageInfos() shows the packages in the process
of being installed. Once the installation process is done,
LatestInactivePackageInfos() returns nothing. If there are packages that
can't be fully activated without a reboot, CurrentlyActivePackageInfos()
will return the same information as LatestActivePackageInfos(), or if
everything has been installed and activated, it will return no packages.

Change-Id: Ia1814a5abda6d815c46e0b46dc812b4e7af81de3
Reviewed-on: https://review.haiku-os.org/c/1129
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 5c9672ed 17-Jun-2014 Ingo Weinhold <ingo_weinhold@gmx.de>

Add watching support for installation location package changes

Can be requested/stopped via BPackageRoster::{Start,Stop}Watching().
The notification message has the what code B_PACKAGE_UPDATE and contains
fields "event", "location", and "change count".


# e6216e37 14-Apr-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Implement getting a BInstallationLocationInfo

* Rename PackageDaemonDefs.h to DaemonDefs.h.
* Replace the MESSAGE_GET_PACKAGES by the new
B_MESSAGE_GET_INSTALLATION_LOCATION_INFO, which not only returns the
packages, but also other information about the installation location.
* daemon: Volume: Implement a change count which is bumped whenever
packages are activated/deactivated/added/removed. Cache the reply
for a location info request, using the change count to check whether
it is still up-to-date.
* Add private BDaemonClient for communication with the daemon.
* BRoster:
- Add GetInstallationLocationInfo() using BDaemonClient.
- Reimplement GetActivePackages(), using
GetInstallationLocationInfo().


# 9213e9d6 16-Jul-2011 Ingo Weinhold <ingo_weinhold@gmx.de>

Add BPackageRoster::GetActivePackages()

The implementation is temporary. Currently it reads through the packages
in the respective packages directory and checks against the package
links. Once package activation is tracked explicitly we'll use the
activation file/directory.


# 9968845d 16-Jul-2011 Ingo Weinhold <ingo_weinhold@gmx.de>

Use BStringList in package kit

Replace all instances of BObjectList<BString> by BStringList.


# 8c29f587 16-Jul-2011 Ingo Weinhold <ingo_weinhold@gmx.de>

Add BPackageRoster::GetActivePackages()

The implementation is temporary. Currently it reads through the packages
in the respective packages directory and checks against the package
links. Once package activation is tracked explicitly we'll use the
activation file/directory.


# 2021c984 16-Jul-2011 Ingo Weinhold <ingo_weinhold@gmx.de>

Use BStringList in package kit

Replace all instances of BObjectList<BString> by BStringList.


# 0d6b3b20 27-Jan-2011 Oliver Tappe <zooey@hirschkaefer.de>

More work on package kit:
* added class BPackageInfo, which contains packaging attributes of
a package (the values relevant for package management)
* implemented parser (mostly) for reading a BPackageInfo from a config
file (.PackageInfo) in order to pass them on to the PackageWriter
when creating a package
* pulled hpkg-related stuff from bin/package into the package kit
* adjusted packagefs-Volume to skip .PackageInfo files when populating
the mountpoint, as those files shouldn't appear as part of an
activated package


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40301 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7d7ed9bf 25-Jan-2011 Oliver Tappe <zooey@hirschkaefer.de>

Mostly style-related changes to package kit:
* drop 'Haiku' namespace
* rename 'Package' namespace to 'BPackageKit'
* renamed all public classes to begin with a 'B'
* renamed BPackageKit::Roster to BPackageKit::BPackageRoster to not
clash with the BRoster from the application kit.
* fix some instances of public headers including private ones

Some functional changes, too:
* JobQueue now removes and deletes dependants of failed jobs
automatically
* JobQueue supports waiting for jobs to become runnable
* added a couple of InitCheck() methods where they make sense
and invoke those in users of these classes



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40287 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5c9672edebef5990fe9fc81fa917287448ac1ac4 17-Jun-2014 Ingo Weinhold <ingo_weinhold@gmx.de>

Add watching support for installation location package changes

Can be requested/stopped via BPackageRoster::{Start,Stop}Watching().
The notification message has the what code B_PACKAGE_UPDATE and contains
fields "event", "location", and "change count".


# e6216e372af01cc90339fe7afb70c113c99974bd 14-Apr-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Implement getting a BInstallationLocationInfo

* Rename PackageDaemonDefs.h to DaemonDefs.h.
* Replace the MESSAGE_GET_PACKAGES by the new
B_MESSAGE_GET_INSTALLATION_LOCATION_INFO, which not only returns the
packages, but also other information about the installation location.
* daemon: Volume: Implement a change count which is bumped whenever
packages are activated/deactivated/added/removed. Cache the reply
for a location info request, using the change count to check whether
it is still up-to-date.
* Add private BDaemonClient for communication with the daemon.
* BRoster:
- Add GetInstallationLocationInfo() using BDaemonClient.
- Reimplement GetActivePackages(), using
GetInstallationLocationInfo().


# 9213e9d6a8fb083184b2e9a292f2eab7b61d09f9 16-Jul-2011 Ingo Weinhold <ingo_weinhold@gmx.de>

Add BPackageRoster::GetActivePackages()

The implementation is temporary. Currently it reads through the packages
in the respective packages directory and checks against the package
links. Once package activation is tracked explicitly we'll use the
activation file/directory.


# 9968845d6988000a9235d7eb09031e80d997f31d 16-Jul-2011 Ingo Weinhold <ingo_weinhold@gmx.de>

Use BStringList in package kit

Replace all instances of BObjectList<BString> by BStringList.


# 8c29f587282dbe71860169bfe1c9832c659f14c0 16-Jul-2011 Ingo Weinhold <ingo_weinhold@gmx.de>

Add BPackageRoster::GetActivePackages()

The implementation is temporary. Currently it reads through the packages
in the respective packages directory and checks against the package
links. Once package activation is tracked explicitly we'll use the
activation file/directory.


# 2021c9842e1e61a3bf0f6550725ec3baf53d44b1 16-Jul-2011 Ingo Weinhold <ingo_weinhold@gmx.de>

Use BStringList in package kit

Replace all instances of BObjectList<BString> by BStringList.


# 0d6b3b20e15fe2cbeb5e81749f888c26ca289338 27-Jan-2011 Oliver Tappe <zooey@hirschkaefer.de>

More work on package kit:
* added class BPackageInfo, which contains packaging attributes of
a package (the values relevant for package management)
* implemented parser (mostly) for reading a BPackageInfo from a config
file (.PackageInfo) in order to pass them on to the PackageWriter
when creating a package
* pulled hpkg-related stuff from bin/package into the package kit
* adjusted packagefs-Volume to skip .PackageInfo files when populating
the mountpoint, as those files shouldn't appear as part of an
activated package


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40301 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7d7ed9bf4bdd7bc31e31143c402c4f96a324b30b 25-Jan-2011 Oliver Tappe <zooey@hirschkaefer.de>

Mostly style-related changes to package kit:
* drop 'Haiku' namespace
* rename 'Package' namespace to 'BPackageKit'
* renamed all public classes to begin with a 'B'
* renamed BPackageKit::Roster to BPackageKit::BPackageRoster to not
clash with the BRoster from the application kit.
* fix some instances of public headers including private ones

Some functional changes, too:
* JobQueue now removes and deletes dependants of failed jobs
automatically
* JobQueue supports waiting for jobs to become runnable
* added a couple of InitCheck() methods where they make sense
and invoke those in users of these classes



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40287 a95241bf-73f2-0310-859d-f6bbb57e9c96