21 lines
383 B
C++
21 lines
383 B
C++
|
#include "group.h"
|
||
|
#include "package.h"
|
||
|
|
||
|
#include <QJsonArray>
|
||
|
|
||
|
namespace PackageManagement {
|
||
|
|
||
|
/*!
|
||
|
* \brief Returns the package names of the group as QJsonArray.
|
||
|
*/
|
||
|
QJsonArray AlpmGroup::packageNames() const
|
||
|
{
|
||
|
QJsonArray pkgNames;
|
||
|
for(AlpmPackage pkg : packages()) {
|
||
|
pkgNames << QString::fromLocal8Bit(pkg.name());
|
||
|
}
|
||
|
return pkgNames;
|
||
|
}
|
||
|
|
||
|
} // namespace Alpm
|