original_string: protected function findPrice(PriceInterface $searchPrice): ?PriceInterface
      {
          foreach ($this->prices as $price) {
              if ($price->getAmount() == $searchPrice->getAmount() && $price->getB2bGroupId() == $searchPrice->getB2bGroupId() && $price->getCurrency()->getId() == $searchPrice->getCurrency()->getId()) {
                  return $price;
              }
          }
  
          return null;
      }
code: protected function findPrice(PriceInterface $searchPrice): ?PriceInterface
      {
          foreach ($this->prices as $price) {
              if ($price->getAmount() == $searchPrice->getAmount() && $price->getB2bGroupId() == $searchPrice->getB2bGroupId() && $price->getCurrency()->getId() == $searchPrice->getCurrency()->getId()) {
                  return $price;
              }
          }
  
          return null;
      }
code_tokens: protected function findPrice ( PriceInterface $ searchPrice ) : ? PriceInterface { foreach ( $ this -> prices as $ price ) { if ( $ price -> getAmount ( ) == $ searchPrice -> getAmount ( ) && $ price -> getB2bGroupId ( ) == $ searchPrice -> getB2bGroupId ( ) && $ price -> getCurrency ( ) -> getId ( ) == $ searchPrice -> getCurrency ( ) -> getId ( ) ) { return $ price ; } } return null ; }
docstring: This method will try to find a price based on the unique constraint defined in price.
  
  @param PriceInterface $searchPrice
  
  @return PriceInterface|null
docstring_tokens: This method will try to find a price based on the unique constraint defined in price .