Main Page   Namespace List   Compound List   File List   Namespace Members   Compound Members   File Members  

MediaInfoLib::MediaInfoList Class Reference

MediaInfoList. More...

#include <MediaInfoList.h>

List of all members.

Public Member Functions

 MediaInfoList (int MaxCount=1000)
 Constructor.

int Open (const std::string &File, const fileoptions_t Options=FileOption_Nothing)
 Open one or more files.

int Save (int FilePos)
 Save file.

int Save_All ()
 Save all files.

void Close (int FilePos)
 Close file (without saving).

void Close_All ()
 Close all files.

std::string Inform (int FilePos, informoptions_t Options=InformOption_Nothing)
 Get all details about a file in one string.

std::string Inform_All (informoptions_t Options=InformOption_Nothing, const std::string &Separator=std::string("\r\n\r\n---\r\n\r\n"))
 Get all details about all files in one string.

std::string Get (int FilePos, stream_t StreamKind, int StreamNumber, int Parameter, info_t KindOfInfo=Info_Text)
 Get information about a file (parameter is an integer).

std::string Get (int FilePos, stream_t StreamKind, int StreamNumber, const std::string &Parameter, info_t KindOfInfo=Info_Text, info_t KindOfSearch=Info_Name)
 Get information about a file (parameter is a string).

int Set (const std::string &ToSet, int FilePos, stream_t StreamKind, int StreamNumber, int Parameter, info_t KindOfInfo=Info_Text)
 Set information about a file (parameter is an int).

int Set (const std::string &ToSet, int FilePos, stream_t StreamKind, int StreamNumber, const std::string &Parameter, info_t KindOfInfo=Info_Text, info_t KindOfSearch=Info_Name)
 Get information about a file (parameter is a string).

int Count_Get ()
 Get the number of opened files.

int Count_Get (int FilePos, stream_t StreamKind, int StreamNumber=-1)
 Count of streams of a certain kind, or count of info in this stream (if StreamNumber).

int Language_Set (const std::string &NewLanguage)
 Configure custom text.


Static Public Member Functions

int Complete_Get ()
 For debug, show all info (doesn't care of InfoOption_NoShow tag).

int Complete_Set (bool Complete)
 For debug, show all info (doesn't care of InfoOption_NoShow tag).

int Language_Set_Static (const std::string &NewLanguage)
 Configure custom text (static).

int Inform_Set (const std::string &NewView)
 Configure custom text.

std::string Info_Parameters (bool CSV=false)
 Information about what are known unique names for parameters.

std::string Info_Capacities ()
 Information about which parameters per format are supported.

std::string Info_Codecs ()
 Information about which codec is known.

std::string Info_Version ()
 Get the version of MediaInfoLib.


Detailed Description

MediaInfoList.

Version:
0.4.0 beta

Definition at line 83 of file MediaInfoList.h.


Constructor & Destructor Documentation

MediaInfoLib::MediaInfoList::MediaInfoList int    MaxCount = 1000
 

Constructor.

Parameters:
MaxCount Max number of files we have to handle


Member Function Documentation

void MediaInfoLib::MediaInfoList::Close int    FilePos
 

Close file (without saving).

Warning:
without have saved before, modifications are lost
Remarks:
All positions of files upper than FilePos are shifted
Return values:
>=0 number of files saved

void MediaInfoLib::MediaInfoList::Close_All  
 

Close all files.

Close all files (without saving)

Warning:
without have saved before, modifications are lost

int MediaInfoLib::MediaInfoList::Complete_Get   [static]
 

For debug, show all info (doesn't care of InfoOption_NoShow tag).

int MediaInfoLib::MediaInfoList::Complete_Set bool    Complete [static]
 

For debug, show all info (doesn't care of InfoOption_NoShow tag).

Parameters:
Complete false if you want show only intersting tags true if you want show all tags

int MediaInfoLib::MediaInfoList::Count_Get int    FilePos,
stream_t    StreamKind,
int    StreamNumber = -1
 

Count of streams of a certain kind, or count of info in this stream (if StreamNumber).

Parameters:
FilePos File position
StreamKind Kind of stream (general, video, audio...)
StreamNumber Stream number in this kind of stream (first, second...)

int MediaInfoLib::MediaInfoList::Count_Get  
 

Get the number of opened files.

Options

Returns:
nmber of files opened

std::string MediaInfoLib::MediaInfoList::Get int    FilePos,
stream_t    StreamKind,
int    StreamNumber,
const std::string &    Parameter,
info_t    KindOfInfo = Info_Text,
info_t    KindOfSearch = Info_Name
 

Get information about a file (parameter is a string).

Parameters:
FilePos File position
StreamKind Kind of stream (general, video, audio...)
StreamNumber Stream number in Kind of stream (first, second...)
Parameter Parameter you are looking for in the stream (Codec, width, bitrate...), in string format ("Codec", "Width"...)
See Info_Parameters() to have the full list
KindOfInfo Kind of info you want about the parameter (the text, the measure, the help...)
KindOfSearch Where to look for the parameter
Returns:
a string about info you search
an empty string if there is a problem

std::string MediaInfoLib::MediaInfoList::Get int    FilePos,
stream_t    StreamKind,
int    StreamNumber,
int    Parameter,
info_t    KindOfInfo = Info_Text
 

Get information about a file (parameter is an integer).

Parameters:
FilePos File position
StreamKind Kind of stream (general, video, audio...)
StreamNumber Stream number in Kind of stream (first, second...)
Parameter Parameter you are looking for in the stream (Codec, width, bitrate...), in integer format (first parameter, second parameter...)
KindOfInfo Kind of info you want about the parameter (the text, the measure, the help...)
Returns:
a string about info you search
an empty string if there is a problem

std::string MediaInfoLib::MediaInfoList::Info_Capacities   [static]
 

Information about which parameters per format are supported.

std::string MediaInfoLib::MediaInfoList::Info_Codecs   [static]
 

Information about which codec is known.

std::string MediaInfoLib::MediaInfoList::Info_Parameters bool    CSV = false [static]
 

Information about what are known unique names for parameters.

Parameters:
CSV false = separated by spaces true = separated by ;

std::string MediaInfoLib::MediaInfoList::Info_Version   [static]
 

Get the version of MediaInfoLib.

std::string MediaInfoLib::MediaInfoList::Inform int    FilePos,
informoptions_t    Options = InformOption_Nothing
 

Get all details about a file in one string.

Inform about a file in text mode

Parameters:
FilePos File position to inform
Precondition:
change defaults with Inform_Set()

std::string MediaInfoLib::MediaInfoList::Inform_All informoptions_t    Options = InformOption_Nothing,
const std::string &    Separator = std::string("\r\n\r\n---\r\n\r\n")
 

Get all details about all files in one string.

Parameters:
Separator Separator string between files descriptions
Precondition:
change defaults with Inform_Set()

int MediaInfoLib::MediaInfoList::Inform_Set const std::string &    NewView [static]
 

Configure custom text.

Parameters:
Language Description of views (CSV format)
Column 1 : code ("General", "Video", "Audio", "Text", "Chapters")
Column 2 : The text to show
Postcondition:
See Inform() and Inform_All() functions

int MediaInfoLib::MediaInfoList::Language_Set const std::string &    NewLanguage
 

Configure custom text.

Parameters:
Language Description of views (CSV format)
Column 1 : code (6 lines : "General", "Video", "Audio", "Text", "Chapters", "Images")
Column 2 : The text to show (exemple : "Audio : FileName% is at BitRate_String%")
Postcondition:
See Inform() function

int MediaInfoLib::MediaInfoList::Language_Set_Static const std::string &    NewLanguage [static]
 

Configure custom text (static).

Parameters:
Language Description of views (CSV format)
Column 1 : code (6 lines : "General", "Video", "Audio", "Text", "Chapters", "Images")
Column 2 : The text to show (exemple : "Audio : FileName% is at BitRate_String%")
Postcondition:
See Inform() function

int MediaInfoLib::MediaInfoList::Open const std::string &    File,
const fileoptions_t    Options = FileOption_Nothing
 

Open one or more files.

Parameters:
File File to open (files must be separated by "|")
Folder to open
Options MEDIAINFOLIB_RECURSIVE = Recursive mode for folders
MEDIAINFOLIB_CLOSE = Close all files before
Return values:
>=0 Number of files added

int MediaInfoLib::MediaInfoList::Save int    FilePos
 

Save file.

Save file

Parameters:
FilePos File position to save
Return values:
>=0 suceed
<0 failed

int MediaInfoLib::MediaInfoList::Save_All  
 

Save all files.

Save all files

int MediaInfoLib::MediaInfoList::Set const std::string &    ToSet,
int    FilePos,
stream_t    StreamKind,
int    StreamNumber,
const std::string &    Parameter,
info_t    KindOfInfo = Info_Text,
info_t    KindOfSearch = Info_Name
 

Get information about a file (parameter is a string).

Parameters:
FilePos File position
StreamKind Kind of stream (general, video, audio...)
StreamNumber Stream number in Kind of stream (first, second...)
Parameter Parameter you are looking for in the stream (Codec, width, bitrate...), in string format ("Codec", "Width"...)
See Info_Parameters() to have the full list
KindOfInfo Kind of info you want about the parameter (the text, the measure, the help...)
Return values:
>=0 suceed
<0 failed

int MediaInfoLib::MediaInfoList::Set const std::string &    ToSet,
int    FilePos,
stream_t    StreamKind,
int    StreamNumber,
int    Parameter,
info_t    KindOfInfo = Info_Text
 

Set information about a file (parameter is an int).

Parameters:
FilePos File position
StreamKind Kind of stream (general, video, audio...)
StreamNumber Stream number in Kind of stream (first, second...)
Parameter Parameter you are looking for in the stream (Codec, width, bitrate...), in integer format (first parameter, second parameter...)
KindOfInfo Kind of info you want about the parameter (the text, the measure, the help...)
Return values:
>=0 suceed
<0 failed


The documentation for this class was generated from the following file:
Generated on Mon Aug 25 23:59:40 2003 for MediaInfoLib by doxygen1.3-rc3