コード例 #1
0
ファイル: Cset.php プロジェクト: hausdesign/zf-library
 /**
  * Constructs the class with given parameters and options.
  *
  * @param HausDesign_Io_Reader $reader  The reader object.
  */
 public function __construct($reader)
 {
     parent::__construct($reader);
     $this->_codePage = $this->_reader->readUInt16LE();
     $this->_countryCode = $this->_reader->readUInt16LE();
     $this->_language = $this->_reader->readUInt16LE();
     $this->_dialect = $this->_reader->readUInt16LE();
 }
コード例 #2
0
 /**
  * Constructs the class with given parameters and options.
  *
  * @param HausDesign_Io_Reader $reader  The reader object.
  */
 public function __construct($reader)
 {
     parent::__construct($reader);
     $startOffset = $this->_reader->getOffset();
     $this->_type = $this->_reader->read(4);
     while ($this->_reader->getOffset() - $startOffset < $this->_size) {
         $offset = $this->_reader->getOffset();
         $identifier = $this->_reader->read(4);
         $size = $this->_reader->readUInt32LE();
         $this->_reader->setOffset($offset);
         if (@fopen($file = 'HausDesign/Media/Riff/Chunk/' . ucfirst(strtolower(rtrim($identifier, ' '))) . '.php', 'r', true) !== false) {
             require_once $file;
         }
         if (class_exists($classname = 'HausDesign_Media_Riff_Chunk_' . ucfirst(strtolower(rtrim($identifier, ' '))))) {
             $this->_chunks[] = new $classname($this->_reader);
             $this->_reader->setOffset($offset + 8 + $size);
         } else {
             trigger_error('Unknown RIFF chunk: \'' . $identifier . '\' skipped', E_USER_WARNING);
             $this->_reader->skip(8 + $size);
         }
     }
 }
コード例 #3
0
ファイル: Ctoc.php プロジェクト: hausdesign/zf-library
 /**
  * Constructs the class with given parameters and options.
  *
  * @param HausDesign_Io_Reader $reader  The reader object.
  */
 public function __construct($reader)
 {
     parent::__construct($reader);
     require_once 'HausDesign/Media/Riff/Exception.php';
     throw new HausDesign_Media_Riff_Exception('Not yet implemented');
 }
コード例 #4
0
ファイル: StringChunk.php プロジェクト: hausdesign/zf-library
 /**
  * Constructs the class with given parameters and options.
  *
  * @param HausDesign_Io_Reader $reader  The reader object.
  */
 public function __construct($reader)
 {
     parent::__construct($reader);
     $this->_value = rtrim($this->_reader->read($this->_size), "");
 }
コード例 #5
0
ファイル: Id3.php プロジェクト: hausdesign/zf-library
 /**
  * Constructs the class with given parameters and options.
  *
  * @param HausDesign_Io_Reader $reader  The reader object.
  */
 public function __construct($reader)
 {
     parent::__construct($reader);
     $this->_tag = new HausDesign_Media_Id3v2($this->_reader, array('readonly' => true));
 }