mirror of
https://github.com/parchlinux/calamares.git
synced 2025-06-28 18:05:36 -04:00
[contextualprocess] Helper methods for counting checks
This commit is contained in:
parent
8664400ee9
commit
87e2f13dc2
2 changed files with 20 additions and 0 deletions
|
@ -175,4 +175,19 @@ ContextualProcessJob::setConfigurationMap( const QVariantMap& configurationMap )
|
|||
}
|
||||
}
|
||||
|
||||
int
|
||||
ContextualProcessJob::count()
|
||||
{
|
||||
return m_commands.count();
|
||||
}
|
||||
|
||||
int
|
||||
ContextualProcessJob::count(const QString& variableName)
|
||||
{
|
||||
for ( const ContextualProcessBinding* binding : m_commands )
|
||||
if ( binding->variable == variableName )
|
||||
return binding->checks.count();
|
||||
return -1;
|
||||
}
|
||||
|
||||
CALAMARES_PLUGIN_FACTORY_DEFINITION( ContextualProcessJobFactory, registerPlugin<ContextualProcessJob>(); )
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue