Advertisement
Guest User

Untitled

a guest
Mar 14th, 2017
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.40 KB | None | 0 0
  1. <?php
  2.  
  3. namespace CalculatorBundle\Entity;
  4.  
  5. class Calculator{
  6.     /**
  7.      * @var float
  8.      */
  9.     private $leftOperand;
  10.  
  11.     /**
  12.      * @var float
  13.      */
  14.     private $rightOperand;
  15.  
  16.     /**
  17.      * @var string
  18.      */
  19.     private $operator;
  20.  
  21.     /**
  22.      * Get  left operand
  23.      * @return float
  24.      */
  25.     public function getLeftOperand(){
  26.         return $this->leftOperand;
  27.     }
  28.  
  29.     /**
  30.      * set left operand
  31.      *
  32.      * @param float $operand
  33.      *
  34.      * @return Calculator
  35.      */
  36.  
  37.     public function setLeftOperand($operand){
  38.         $this->leftOperand = $operand;
  39.  
  40.         return $this;
  41.     }
  42.  
  43.     /**
  44.      * Get right operand
  45.      *
  46.      * @return float
  47.      */
  48.     public function getRightOperand(){
  49.         return $this->rightOperand;
  50.     }
  51.  
  52.     /**
  53.      * set right operand
  54.      * @param float $operand
  55.      *
  56.      * @return Calculator
  57.      */
  58.     public function setRightOperand($operand){
  59.         $this->rightOperand = $operand;
  60.  
  61.         return $this;
  62.     }
  63.  
  64.     /**
  65.      * Get operator
  66.      *
  67.      * @return float
  68.      */
  69.     public function getOperand(){
  70.         return $this->operator;
  71.     }
  72.  
  73.     /**
  74.      * set right $operator
  75.      *
  76.      * @param string $operator
  77.      *
  78.      *
  79.      * @return Calculator
  80.      */
  81.     public function setOperator($operator){
  82.         $this->operator = $operator;
  83.  
  84.         return $this;
  85.     }
  86. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement