ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
AMFStream Class Reference
+ Collaboration diagram for AMFStream:

Public Member Functions

 AMFStream (&$bytes)
 
 readByte ()
 
 readInt ()
 
 readLong ()
 
 readDouble ()
 
 readUTF ()
 
 readLongUTF ()
 
 read ($length)
 
 peekByte ()
 
 peekInt ()
 
 peekLong ()
 
 peekDouble ()
 
 peekUTF ()
 
 peekLongUTF ()
 
 __construct (&$bytes)
 
 readByte ()
 
 readInt ()
 
 readLong ()
 
 readDouble ()
 
 readUTF ()
 
 readLongUTF ()
 
 read ($length)
 
 peekByte ()
 
 peekInt ()
 
 peekLong ()
 
 peekDouble ()
 
 peekUTF ()
 
 peekLongUTF ()
 

Data Fields

 $bytes
 
 $pos
 

Detailed Description

Definition at line 248 of file module.audio-video.flv.php.

Constructor & Destructor Documentation

◆ __construct()

AMFStream::__construct ( $bytes)

Definition at line 393 of file module.audio-video.flv.php.

393 {
394 $this->bytes =& $bytes;
395 $this->pos = 0;
396 }

References $bytes.

Member Function Documentation

◆ AMFStream()

AMFStream::AMFStream ( $bytes)

Definition at line 252 of file module.audio-video.flv.php.

252 {
253 $this->bytes =& $bytes;
254 $this->pos = 0;
255 }

References $bytes.

◆ peekByte() [1/2]

AMFStream::peekByte ( )

Definition at line 289 of file module.audio-video.flv.php.

289 {
291 $val = $this->readByte();
292 $this->pos = $pos;
293 return $val;
294 }

References $pos, and readByte().

+ Here is the call graph for this function:

◆ peekByte() [2/2]

AMFStream::peekByte ( )

Definition at line 430 of file module.audio-video.flv.php.

430 {
432 $val = $this->readByte();
433 $this->pos = $pos;
434 return $val;
435 }

References $pos, and readByte().

+ Here is the call graph for this function:

◆ peekDouble() [1/2]

AMFStream::peekDouble ( )

Definition at line 310 of file module.audio-video.flv.php.

310 {
312 $val = $this->readDouble();
313 $this->pos = $pos;
314 return $val;
315 }

References $pos, and readDouble().

+ Here is the call graph for this function:

◆ peekDouble() [2/2]

AMFStream::peekDouble ( )

Definition at line 451 of file module.audio-video.flv.php.

451 {
453 $val = $this->readDouble();
454 $this->pos = $pos;
455 return $val;
456 }

References $pos, and readDouble().

+ Here is the call graph for this function:

◆ peekInt() [1/2]

AMFStream::peekInt ( )

Definition at line 296 of file module.audio-video.flv.php.

296 {
298 $val = $this->readInt();
299 $this->pos = $pos;
300 return $val;
301 }

References $pos, and readInt().

+ Here is the call graph for this function:

◆ peekInt() [2/2]

AMFStream::peekInt ( )

Definition at line 437 of file module.audio-video.flv.php.

437 {
439 $val = $this->readInt();
440 $this->pos = $pos;
441 return $val;
442 }

References $pos, and readInt().

+ Here is the call graph for this function:

◆ peekLong() [1/2]

AMFStream::peekLong ( )

Definition at line 303 of file module.audio-video.flv.php.

303 {
305 $val = $this->readLong();
306 $this->pos = $pos;
307 return $val;
308 }

References $pos, and readLong().

+ Here is the call graph for this function:

◆ peekLong() [2/2]

AMFStream::peekLong ( )

Definition at line 444 of file module.audio-video.flv.php.

444 {
446 $val = $this->readLong();
447 $this->pos = $pos;
448 return $val;
449 }

References $pos, and readLong().

+ Here is the call graph for this function:

◆ peekLongUTF() [1/2]

AMFStream::peekLongUTF ( )

Definition at line 324 of file module.audio-video.flv.php.

324 {
326 $val = $this->readLongUTF();
327 $this->pos = $pos;
328 return $val;
329 }

References $pos, and readLongUTF().

+ Here is the call graph for this function:

◆ peekLongUTF() [2/2]

AMFStream::peekLongUTF ( )

Definition at line 465 of file module.audio-video.flv.php.

465 {
467 $val = $this->readLongUTF();
468 $this->pos = $pos;
469 return $val;
470 }

References $pos, and readLongUTF().

+ Here is the call graph for this function:

◆ peekUTF() [1/2]

AMFStream::peekUTF ( )

Definition at line 317 of file module.audio-video.flv.php.

317 {
319 $val = $this->readUTF();
320 $this->pos = $pos;
321 return $val;
322 }

References $pos, and readUTF().

+ Here is the call graph for this function:

◆ peekUTF() [2/2]

AMFStream::peekUTF ( )

Definition at line 458 of file module.audio-video.flv.php.

458 {
460 $val = $this->readUTF();
461 $this->pos = $pos;
462 return $val;
463 }

References $pos, and readUTF().

+ Here is the call graph for this function:

◆ read() [1/2]

AMFStream::read (   $length)

Definition at line 283 of file module.audio-video.flv.php.

283 {
284 $val = substr($this->bytes, $this->pos, $length);
285 $this->pos += $length;
286 return $val;
287 }

Referenced by readDouble(), readLongUTF(), and readUTF().

+ Here is the caller graph for this function:

◆ read() [2/2]

AMFStream::read (   $length)

Definition at line 424 of file module.audio-video.flv.php.

424 {
425 $val = substr($this->bytes, $this->pos, $length);
426 $this->pos += $length;
427 return $val;
428 }

◆ readByte() [1/2]

AMFStream::readByte ( )

Definition at line 257 of file module.audio-video.flv.php.

257 {
258 return getid3_lib::BigEndian2Int(substr($this->bytes, $this->pos++, 1));
259 }
BigEndian2Int($byteword, $synchsafe=false, $signed=false)
Definition: getid3.lib.php:234

References getid3_lib\BigEndian2Int().

Referenced by peekByte(), readInt(), and readLong().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ readByte() [2/2]

AMFStream::readByte ( )

Definition at line 398 of file module.audio-video.flv.php.

398 {
399 return getid3_lib::BigEndian2Int(substr($this->bytes, $this->pos++, 1));
400 }

References getid3_lib\BigEndian2Int().

+ Here is the call graph for this function:

◆ readDouble() [1/2]

AMFStream::readDouble ( )

Definition at line 269 of file module.audio-video.flv.php.

269 {
270 return getid3_lib::BigEndian2Float($this->read(8));
271 }
BigEndian2Float($byteword)
Definition: getid3.lib.php:159

References getid3_lib\BigEndian2Float(), and read().

Referenced by peekDouble().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ readDouble() [2/2]

AMFStream::readDouble ( )

Definition at line 410 of file module.audio-video.flv.php.

410 {
411 return getid3_lib::BigEndian2Float($this->read(8));
412 }

References getid3_lib\BigEndian2Float(), and read().

+ Here is the call graph for this function:

◆ readInt() [1/2]

AMFStream::readInt ( )

Definition at line 261 of file module.audio-video.flv.php.

261 {
262 return ($this->readByte() << 8) + $this->readByte();
263 }

References readByte().

Referenced by peekInt(), and readUTF().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ readInt() [2/2]

AMFStream::readInt ( )

Definition at line 402 of file module.audio-video.flv.php.

402 {
403 return ($this->readByte() << 8) + $this->readByte();
404 }

References readByte().

+ Here is the call graph for this function:

◆ readLong() [1/2]

AMFStream::readLong ( )

Definition at line 265 of file module.audio-video.flv.php.

265 {
266 return ($this->readByte() << 24) + ($this->readByte() << 16) + ($this->readByte() << 8) + $this->readByte();
267 }

References readByte().

Referenced by peekLong(), and readLongUTF().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ readLong() [2/2]

AMFStream::readLong ( )

Definition at line 406 of file module.audio-video.flv.php.

406 {
407 return ($this->readByte() << 24) + ($this->readByte() << 16) + ($this->readByte() << 8) + $this->readByte();
408 }

References readByte().

+ Here is the call graph for this function:

◆ readLongUTF() [1/2]

AMFStream::readLongUTF ( )

Definition at line 278 of file module.audio-video.flv.php.

278 {
279 $length = $this->readLong();
280 return $this->read($length);
281 }

References read(), and readLong().

Referenced by peekLongUTF().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ readLongUTF() [2/2]

AMFStream::readLongUTF ( )

Definition at line 419 of file module.audio-video.flv.php.

419 {
420 $length = $this->readLong();
421 return $this->read($length);
422 }

References read(), and readLong().

+ Here is the call graph for this function:

◆ readUTF() [1/2]

AMFStream::readUTF ( )

Definition at line 273 of file module.audio-video.flv.php.

273 {
274 $length = $this->readInt();
275 return $this->read($length);
276 }

References read(), and readInt().

Referenced by peekUTF().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ readUTF() [2/2]

AMFStream::readUTF ( )

Definition at line 414 of file module.audio-video.flv.php.

414 {
415 $length = $this->readInt();
416 return $this->read($length);
417 }

References read(), and readInt().

+ Here is the call graph for this function:

Field Documentation

◆ $bytes

AMFStream::$bytes

Definition at line 249 of file module.audio-video.flv.php.

Referenced by __construct(), and AMFStream().

◆ $pos

AMFStream::$pos

The documentation for this class was generated from the following files: