ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
ilMediaAnalyzer Class Reference

Analyzes media files. More...

+ Collaboration diagram for ilMediaAnalyzer:

Public Member Functions

 __construct ()
 
 setFile ($a_file)
 Set Full File Path. More...
 
 getFile ()
 Get Full File Path. More...
 
 getPlaytimeString ()
 Get PlaytimeString. More...
 
 getPlaytimeSeconds ()
 Get PlaytimeSeconds. More...
 
 analyzeFile ()
 Analyze current file. More...
 

Data Fields

 $file
 

Detailed Description

Analyzes media files.

Wrapper for getid3 library.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

Definition at line 35 of file class.ilMediaAnalyzer.php.

Constructor & Destructor Documentation

◆ __construct()

ilMediaAnalyzer::__construct ( )

Definition at line 39 of file class.ilMediaAnalyzer.php.

40  {
41  //include_once("./Services/MediaObjects/lib/getID3-1.9.10/getid3/getid3.php");
42  //include_once("./libs/composer/vendor/phansys/getid3/GetId3/GetId3.php");
43  //include_once("./Services/MediaObjects/getid3/getid3/getid3.php");
44  //$this->getid3 = new GetId3_GetId3();
45  $this->getid3 = new GetId3();
46  }

Member Function Documentation

◆ analyzeFile()

ilMediaAnalyzer::analyzeFile ( )

Analyze current file.

Definition at line 91 of file class.ilMediaAnalyzer.php.

References getFile().

92  {
93  $this->file_info = $this->getid3->analyze($this->getFile());
94  }
getFile()
Get Full File Path.
+ Here is the call graph for this function:

◆ getFile()

ilMediaAnalyzer::getFile ( )

Get Full File Path.

Returns
string Full File Path

Definition at line 63 of file class.ilMediaAnalyzer.php.

References $file.

Referenced by analyzeFile().

64  {
65  return $this->file;
66  }
+ Here is the caller graph for this function:

◆ getPlaytimeSeconds()

ilMediaAnalyzer::getPlaytimeSeconds ( )

Get PlaytimeSeconds.

Returns
double PlaytimeSeconds

Definition at line 83 of file class.ilMediaAnalyzer.php.

84  {
85  return $this->file_info["playtime_seconds"];
86  }

◆ getPlaytimeString()

ilMediaAnalyzer::getPlaytimeString ( )

Get PlaytimeString.

Returns
string PlaytimeString

Definition at line 73 of file class.ilMediaAnalyzer.php.

74  {
75  return $this->file_info["playtime_string"];
76  }

◆ setFile()

ilMediaAnalyzer::setFile (   $a_file)

Set Full File Path.

Parameters
string$a_fileFull File Path

Definition at line 53 of file class.ilMediaAnalyzer.php.

References file.

54  {
55  $this->file = $a_file;
56  }
Reload workbook from saved file

Field Documentation

◆ $file

ilMediaAnalyzer::$file

Definition at line 37 of file class.ilMediaAnalyzer.php.

Referenced by getFile().


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