<?php

include_once 'Testing/FIT/Fixture.php';
include_once 'Testing/FIT/Fixture/Column.php';


class Math_Calculator extends Testing_FIT_Fixture_Column
{

    protected $_typeDictionary = array(
                                        'a'             => 'float',
                                        'b'             => 'float',
                                        'quotient()'    => 'float',
                                        'sum()'         => 'float',
                                        'sub()'         => 'float',
                                    );

    public $a;
    public $b;

    public function quotient() {
        if( $this->b == 0 ) {
            throw new Exception( 'division by zero' );
        }
        return $this->a / $this->b;
    }

    public function sum() {
        return $this->a + $this->b;
    }

    public function sub() {
        return $this->a - $this->b;
    }
}

?>