code: private function collectObjectIdentifiers(Definition $definition)
      {
          $this->outputHandler->writeLine(sprintf(
              'checking transfer objects for existence: Type: %s, %s -> %s',
              $definition->getObjectType(),
              $definition->getOriginAdapterName(),
              $definition->getDestinationAdapterName()
          ));
  
          /**
           * @var TransferObjectInterface[] $objects
           */
          $objects = $this->serviceBus->handle($this->queryFactory->create(
              $definition->getOriginAdapterName(),
              $definition->getObjectType(),
              QueryType::ALL
          ));
  
          $found = false;
  
          if (empty($objects)) {
              return false;
          }
  
          foreach ($objects as $transferObject) {
              if (false === $found) {
                  $found = true;
              }
  
              $this->elements[] = [
                  'objectIdentifier' => $transferObject->getIdentifier(),
                  'adapterName' => $definition->getDestinationAdapterName(),
                  'type' => $transferObject->getType(),
              ];
          }
  
          return !(false === $found);
      }
docs: @param Definition $definition
  
  @return bool