PageRenderTime 14ms CodeModel.GetById 11ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/src/Zend/Media/Iso14496/Box/Tref.php

http://php-reader.googlecode.com/
PHP | 81 lines | 14 code | 4 blank | 63 comment | 1 complexity | ea27fca0be4e2eac0b652b37ac7701f3 MD5 | raw file
 1<?php
 2/**
 3 * Zend Framework
 4 *
 5 * LICENSE
 6 *
 7 * This source file is subject to the new BSD license that is bundled
 8 * with this package in the file LICENSE.txt.
 9 * It is also available through the world-wide-web at this URL:
10 * http://framework.zend.com/license/new-bsd
11 * If you did not receive a copy of the license and are unable to
12 * obtain it through the world-wide-web, please send an email
13 * to license@zend.com so we can send you a copy immediately.
14 *
15 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS'
16 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
17 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
18 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
19 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
20 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
21 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
22 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
23 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
24 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
25 * POSSIBILITY OF SUCH DAMAGE.
26 *
27 * @category   Zend
28 * @package    Zend_Media
29 * @subpackage ISO14496
30 * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com) 
31 * @license    http://framework.zend.com/license/new-bsd     New BSD License
32 * @version    $Id: Tref.php 177 2010-03-09 13:13:34Z svollbehr $
33 */
34
35/**#@+ @ignore */
36require_once 'Zend/Media/Iso14496/Box.php';
37/**#@-*/
38
39/**
40 * The <i>Track Reference Box</i> provides a reference from the containing track
41 * to another track in the presentation. These references are typed. A
42 * {@link Zend_Media_Iso14496_Box_Hint hint} reference links from the containing
43 * hint track to the media data that it hints. A content description reference
44 * {@link Zend_Media_Iso14496_Box_Cdsc cdsc} links a descriptive or metadata
45 * track to the content which it describes.
46 *
47 * Exactly one Track Reference Box can be contained within the
48 * {@link Zend_Media_Iso14496_Box_Trak Track Box}.
49 *
50 * If this box is not present, the track is not referencing any other track in
51 * any way. The reference array is sized to fill the reference type box.
52 *
53 * @category   Zend
54 * @package    Zend_Media
55 * @subpackage ISO14496
56 * @author     Sven Vollbehr <sven@vollbehr.eu>
57 * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com) 
58 * @license    http://framework.zend.com/license/new-bsd     New BSD License
59 * @version    $Id: Tref.php 177 2010-03-09 13:13:34Z svollbehr $
60 */
61final class Zend_Media_Iso14496_Box_Tref extends Zend_Media_Iso14496_Box
62{
63    /**
64     * Constructs the class with given parameters and reads box related data
65     * from the ISO Base Media file.
66     *
67     * @param Zend_Io_Reader $reader  The reader object.
68     * @param Array          $options The options array.
69     */
70    public function __construct($reader = null, &$options = array())
71    {
72        parent::__construct($reader, $options);
73        $this->setContainer(true);
74
75        if ($reader === null) {
76            return;
77        }
78
79        $this->constructBoxes();
80    }
81}