/src/Zend/Media/Id3/Frame/Tyer.php
http://php-reader.googlecode.com/ · PHP · 73 lines · 17 code · 4 blank · 52 comment · 0 complexity · f593ae489d31cadb189fb6c04ddf9c7d MD5 · raw file
- <?php
- /**
- * Zend Framework
- *
- * LICENSE
- *
- * This source file is subject to the new BSD license that is bundled
- * with this package in the file LICENSE.txt.
- * It is also available through the world-wide-web at this URL:
- * http://framework.zend.com/license/new-bsd
- * If you did not receive a copy of the license and are unable to
- * obtain it through the world-wide-web, please send an email
- * to license@zend.com so we can send you a copy immediately.
- *
- * @category Zend
- * @package Zend_Media
- * @subpackage ID3
- * @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
- * @license http://framework.zend.com/license/new-bsd New BSD License
- * @version $Id: Tyer.php 177 2010-03-09 13:13:34Z svollbehr $
- * @deprecated ID3v2.3.0
- */
- /**#@+ @ignore */
- require_once 'Zend/Media/Id3/DateFrame.php';
- /**#@-*/
- /**
- * The <i>Year</i> frame is a numeric string with a year of the recording.
- *
- * @category Zend
- * @package Zend_Media
- * @subpackage ID3
- * @author Sven Vollbehr <sven@vollbehr.eu>
- * @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
- * @license http://framework.zend.com/license/new-bsd New BSD License
- * @version $Id: Tyer.php 177 2010-03-09 13:13:34Z svollbehr $
- * @deprecated ID3v2.3.0
- */
- final class Zend_Media_Id3_Frame_Tyer extends Zend_Media_Id3_DateFrame
- {
- /**
- * Constructs the class with given parameters and parses object related
- * data.
- *
- * @param Zend_Io_Reader $reader The reader object.
- * @param Array $options The options array.
- */
- public function __construct($reader = null, &$options = array())
- {
- parent::__construct($reader, $options, 'Y');
- }
- /**
- * Returns the year.
- *
- * @return integer
- */
- public function getYear()
- {
- return intval($this->getText());
- }
- /**
- * Sets the year.
- *
- * @param integer $year The year given in four digits.
- */
- public function setYear($year)
- {
- $this->setText(strval($year));
- }
- }