for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Test\TestBundle\Document;
use Tpg\ExtjsBundle\Annotation as Extjs;
use Doctrine\ODM\MongoDB\Mapping\Annotations as ODM;
use JMS\Serializer\Annotation as JMS;
/**
* @Extjs\Model(name="Test.document.OrderLineItem")
* @ODM\EmbeddedDocument
*/
class OrderLineItem {
* @ODM\Int
* @JMS\Type("integer")
protected $productId;
protected $quantity;
* @ODM\Float
* @JMS\Type("double")
protected $price;
protected $total;
* Set productId
*
* @param int $productId
* @return self
public function setProductId($productId)
{
$this->productId = $productId;
return $this;
}
* Get productId
* @return int $productId
public function getProductId()
return $this->productId;
* Set quantity
* @param int $quantity
public function setQuantity($quantity)
$this->quantity = $quantity;
* Get quantity
* @return int $quantity
public function getQuantity()
return $this->quantity;
* Set price
* @param float $price
public function setPrice($price)
$this->price = $price;
* Get price
* @return float $price
public function getPrice()
return $this->price;
* Set total
* @param float $total
public function setTotal($total)
$this->total = $total;
* Get total
* @return float $total
public function getTotal()
return $this->total;
* Static class to create a new instance of OrderLineItem
* @return OrderLineItem
public static function newInstance() {
return new OrderLineItem();