dokeos-backup
[ class tree: dokeos-backup ] [ index: dokeos-backup ] [ all elements ]

Source for file Document.class.php

Documentation is available at Document.class.php

  1. <?php // $Id: Document.class.php 4733 2005-05-02 08:54:49Z bmol $
  2. /*
  3. ============================================================================== 
  4.     Dokeos - elearning and course management software
  5.     
  6.     Copyright (c) 2004 Dokeos S.A.
  7.     Copyright (c) 2003 Ghent University (UGent)
  8.     Copyright (c) 2001 Universite catholique de Louvain (UCL)
  9.     Copyright (c) Bart Mollet (bart.mollet@hogent.be)
  10.     
  11.     For a full list of contributors, see "credits.txt".
  12.     The full license can be read in "license.txt".
  13.     
  14.     This program is free software; you can redistribute it and/or
  15.     modify it under the terms of the GNU General Public License
  16.     as published by the Free Software Foundation; either version 2
  17.     of the License, or (at your option) any later version.
  18.     
  19.     See the GNU General Public License for more details.
  20.     
  21.     Contact address: Dokeos, 44 rue des palais, B-1030 Brussels, Belgium
  22.     Mail: info@dokeos.com
  23. ============================================================================== 
  24. */
  25. require_once('Resource.class.php');
  26. define('DOCUMENT','file');
  27. define('FOLDER','folder');
  28. /**
  29.  * An document
  30.  * @author Bart Mollet <bart.mollet@hogent.be>
  31.  * @package dokeos.backup
  32.  */
  33. class Document extends Resource
  34. {
  35.     var $path;
  36.     var $comment;
  37.     var $file_type;
  38.     var $size;
  39.     var $title;
  40.     /**
  41.      * Create a new Document
  42.      * @param int $id 
  43.      * @param string $path 
  44.      * @param string $comment 
  45.      * @param string $title 
  46.      * @param string $file_type (DOCUMENT or FOLDER);
  47.      * @param int $size 
  48.      */
  49.     function Document($id,$path,$comment,$title,$file_type,$size)
  50.     {
  51.         parent::Resource($id,RESOURCE_DOCUMENT);
  52.         $this->path = 'document'.$path;
  53.         $this->comment = $comment;
  54.         $this->title = $title;
  55.         $this->file_type = $file_type;
  56.         $this->size = $size;
  57.     }
  58.     /**
  59.      * Show this document
  60.      */
  61.     function show()
  62.     {
  63.         parent::show();
  64.         echo substr($this->path,8);    
  65.     }
  66. }
  67. ?>

Documentation generated on Thu, 12 Jun 2008 13:19:06 -0500 by phpDocumentor 1.4.1