Sonata\Component\Order\OrderElementInterface::getRawProduct PHP Method

getRawProduct() public method

public getRawProduct ( ) : string
return string
    public function getRawProduct();

Usage Example

 /**
  * @param OrderElementInterface $orderElement
  * @param string                $type
  * @param string                $format
  *
  * @return \Sonata\Component\Product\ProductInterface
  */
 public function getProductFromRaw(OrderElementInterface $orderElement, $type, $format = 'json')
 {
     return $this->serializer->deserialize(json_encode($orderElement->getRawProduct()), $type, $format);
 }