code: protected function getSupplierDeliveryItemFromEvent(ResourceEventInterface $event)
      {
          $item = $event->getResource();
  
          if (!$item instanceof SupplierDeliveryItemInterface) {
              throw new InvalidArgumentException("Expected instance of SupplierDeliveryItemInterface.");
          }
  
          return $item;
      }
docs: Returns the supplier delivery item from the event.
  
  @param ResourceEventInterface $event
  
  @return SupplierDeliveryItemInterface
  @throws InvalidArgumentException