public function Translator::checkTranslatable

Check whether this translator can handle a particular translation job.

Parameters

\Drupal\tmgmt\JobInterface Job: The Job entity that should be translated.

Return value

\Drupal\tmgmt\Translator\TranslatableResult TRUE if the job can be processed and translated, FALSE otherwise.

Overrides TranslatorInterface::checkTranslatable

File

src/Entity/Translator.php, line 371

Class

Translator
Entity class for the tmgmt_translator entity.

Namespace

Drupal\tmgmt\Entity

Code

public function checkTranslatable(JobInterface $job) {
  if ($plugin = $this
    ->getPlugin()) {
    return $plugin
      ->checkTranslatable($this, $job);
  }
  return TranslatableResult::no(t('Missing provider plugin'));
}