<?php
abstract class MComponent
{
    public $manager; // a shortcut to miolo
    public $page;
    public $owner;
    public $name;
    public $className; // name of control's class_

    public function __construct($name = NULL)
    {
        $this->manager = MIOLO::getInstance();
        $this->page = $this->manager->getPage();
        $this->className = strtolower(get_class($this));
        $this->name  = $name;
        $this->owner = $this;
    }

    public function setName($name)
    {
        $this->name = $name;
    }

    public function getName()
    {
        return $this->name;
    }

    /**
      * Returns a manager (MIOLO) instance.
      *
      * @return MIOLO instance
      */
    public function getManager()
    {
        return $this->manager;
    }
}
?>