Project

General

Profile

Download (916 Bytes) Statistics
| Branch: | Tag: | Revision:
1
<?php
2
/**
3
 * @file
4
 * Class to provide a footnote.
5
 *
6
 * @copyright
7
 *   (C) 2007-2012 EDIT
8
 *   European Distributed Institute of Taxonomy
9
 *   http://www.e-taxonomy.eu
10
 *
11
 *   The contents of this module are subject to the Mozilla
12
 *   Public License Version 1.1.
13
 * @see http://www.mozilla.org/MPL/MPL-1.1.html
14
 */
15

    
16
/**
17
 * Provides a footnote.
18
 */
19
class Footnote {
20
  public $key, $object, $enclosing_tag;
21

    
22
  /**
23
   * Private constructor.
24
   */
25
  public function __construct($footnoteKey, $object, $enclosing_tag = NULL) {
26
    $this->key = $footnoteKey;
27
    $this->object = $object;
28
    $this->enclosing_tag = $enclosing_tag;
29
  }
30

    
31
  /**
32
   * @todo please document this function.
33
   */
34
  public function doRender() {
35

    
36
    $enclosing_tag = null;
37
    if(is_string($this->enclosing_tag)){
38
      $enclosing_tag = $this->enclosing_tag;
39
    }
40

    
41
    return render_footnote($this->key, $this->object, $enclosing_tag);
42
  }
43
}
(5-5/8)