public function PSR4::isExecutable in Drupal 7 to 8/9 Module Upgrader 8
Returns if this conversion applies to the target module. If FALSE, the convert() method will not be called.
Parameters
TargetInterface $target: The target module.
Return value
bool
Overrides ConverterBase::isExecutable
File
- src/
Plugin/ DMU/ Converter/ PSR4.php, line 22
Class
- PSR4
- Plugin annotation @Converter( id = "PSR4", description = @Translation("Moves classes into PSR-4 directory structure.") )
Namespace
Drupal\drupalmoduleupgrader\Plugin\DMU\ConverterCode
public function isExecutable(TargetInterface $target) {
return (bool) $target
->getIndexer('class')
->getQuery()
->countQuery()
->execute();
}