Add BSolverPackageSpecifierList::AppendSpecifiers()
This commit is contained in:
@@ -31,6 +31,9 @@ public:
|
|||||||
const BSolverPackageSpecifier& specifier);
|
const BSolverPackageSpecifier& specifier);
|
||||||
bool AppendSpecifier(BSolverPackage* package);
|
bool AppendSpecifier(BSolverPackage* package);
|
||||||
bool AppendSpecifier(const BString& selectString);
|
bool AppendSpecifier(const BString& selectString);
|
||||||
|
bool AppendSpecifiers(
|
||||||
|
const char* const* selectStrings,
|
||||||
|
int32 count);
|
||||||
void MakeEmpty();
|
void MakeEmpty();
|
||||||
|
|
||||||
BSolverPackageSpecifierList& operator=(
|
BSolverPackageSpecifierList& operator=(
|
||||||
|
|||||||
@@ -115,6 +115,22 @@ BSolverPackageSpecifierList::AppendSpecifier(const BString& selectString)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool
|
||||||
|
BSolverPackageSpecifierList::AppendSpecifiers(const char* const* selectStrings,
|
||||||
|
int32 count)
|
||||||
|
{
|
||||||
|
for (int32 i = 0; i < count; i++) {
|
||||||
|
if (!AppendSpecifier(selectStrings[i])) {
|
||||||
|
for (int32 k = i - 1; k >= 0; k--)
|
||||||
|
fSpecifiers->pop_back();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
BSolverPackageSpecifierList::MakeEmpty()
|
BSolverPackageSpecifierList::MakeEmpty()
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user