<?php
class CPUTemperaturGauge extends AbstractGauge
{
    public function __construct($name, $model) {
        
        $this->setModel($model);
        
        $this->setName($name);
        $this->setMin(0);
        $this->setMax(120);
        $this->setSize(120);
        $this->setMinorTicks(5);
        $this->setGreenZones();
        $this->setYellowZones();
        $this->setRedZones();
        $this->setValueSuffix(" °C"); // FIXME : implement °F
    }
    
    public function setGreenZones($zones = array())
    {
        $zones = array(
            array(
                "from"=> 30,
                "to"=>85
            )
        );
        return parent::setGreenZones($zones);
    }
    
    public function setYellowZones($zones = array())
    {
        $zones = array(
            array(
                "from"=> 85,
                "to"=>95
            )
        );
        return parent::setYellowZones($zones);
    }
    
    public function setRedZones($zones = array())
    {
        $zones = array(
            array(
                "from"=> 95,
                "to"=>120
            )
        );
        return parent::setRedZones($zones);
    } 
}