<?php
class Service_DownloadCounter extends XcBase {

        var $_kernel;

    function Service_DownloadCounter($kernelLink) {
           $this->_localname = 'DownloadCounter';
           $this->XcBase($kernelLink);
           $this->_kernel = $this->srvMainKernel();
           $this->advOnto = $this->_kernel->srvFactory("AdvOntology");
    }

    function onInstall($params) {
           $advOnto = $this->advOnto;

           $this->advOnto->addType("DownCounter", "varchar(250)");
           $this->advOnto->addTypeField("DownCounter", "dcnt", "int(5)", "1");

           return true;
    }

    function onUninstall($params) {
           $this->advOnto->delType("DownCounter");
           return true;
    }


}

?>