function ArchivePeriod($site, $s_date, $s_date2, $typePeriod)
 {
     parent::Archive($site);
     $this->setPeriodType($typePeriod);
     $this->date = $this->offsetDate(new Date($s_date));
     $this->date2 = $this->offsetDate(new Date($s_date2));
 }
 /**
  * constructor
  * 
  * @param object $site
  * @param string $s_date
  */
 function ArchiveDay($site, $s_date = '')
 {
     parent::Archive($site);
     /*print($s_date);
     		print("<pre>");
     		debug_print_backtrace();
     		print("</pre>");
     		*/
     $this->setPeriodType(DB_ARCHIVES_PERIOD_DAY);
     if (!empty($s_date)) {
         $this->setDate($s_date);
     }
     $this->objects['provider'] = new ArchiveTable('provider');
     $this->objects['treeCategory'] = new ArchiveCategory($this->site->getId());
     $a_archiveTable = array('provider', 'config', 'resolution', 'vars_name', 'vars_value', 'page', 'file', 'category', 'search_engine', 'keyword', 'site', 'newsletter', 'partner_name', 'partner_url');
     foreach ($a_archiveTable as $name) {
         $this->objects[$name] = new ArchiveTable($name);
     }
 }
 function ArchiveEmpty($site, $s_date, $type)
 {
     parent::Archive($site);
     $this->setPeriodType($type);
     $this->date = new Date($s_date);
 }