F:/Programmation/MediaInfoLib/Source/MediaInfo/MediaInfoList.h

Go to the documentation of this file.
00001 // MediaInfoList - A list of MediaInfo
00002 // Copyright (C) 2002-2007 Jerome Martinez, Zen@MediaArea.net
00003 //
00004 // This library is free software: you can redistribute it and/or modify it
00005 // under the terms of the GNU Lesser General Public License as published by
00006 // the Free Software Foundation, either version 3 of the License, or
00007 // any later version.
00008 //
00009 // This library is distributed in the hope that it will be useful,
00010 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00011 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012 // GNU Lesser General Public License for more details.
00013 //
00014 // You should have received a copy of the GNU Lesser General Public License
00015 // along with this library. If not, see <http://www.gnu.org/licenses/>.
00016 //
00017 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
00018 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
00019 // MediaInfoList
00020 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
00021 //
00022 // Give information about a lot of media files
00023 //
00024 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
00025 
00026 //---------------------------------------------------------------------------
00027 #ifndef MediaInfoListH
00028 #define MediaInfoListH
00029 //---------------------------------------------------------------------------
00030 
00031 //---------------------------------------------------------------------------
00032 #include "MediaInfo/MediaInfo.h"
00033 #include <vector>
00034 //---------------------------------------------------------------------------
00035 
00036 namespace MediaInfoLib
00037 {
00038 
00039 //***************************************************************************
00042 //***************************************************************************
00043 
00044 class MediaInfoList
00045 {
00046 public :
00047     //Class
00050     MediaInfoList (size_t Count_Init=64);
00051     ~MediaInfoList ();
00052 
00053     //Files
00062     size_t Open (const String &File, const fileoptions_t Options=FileOption_Nothing);
00072     size_t Open (const ZenLib::int8u* Begin, size_t Begin_Size, const ZenLib::int8u* End=NULL, size_t End_Size=NULL, ZenLib::int64u File_Size=0);
00079     size_t Save (size_t FilePos);
00085     void Close (size_t FilePos=(size_t)-1);
00086 
00093     String Inform (size_t FilePos=(size_t)-1, size_t Reserved=0);
00094 
00095     //Get
00106     String Get (size_t FilePos, stream_t StreamKind, size_t StreamNumber, size_t Parameter, info_t KindOfInfo=Info_Text); //Get info, FilePos=File position, StreamKind=General video audio text chapter, StreamNumber=stream number, PosInStream=parameter you want, KindOfInfo=name, text, measure, options, name (language), measure (language), info, how to
00119     String Get (size_t FilePos, stream_t StreamKind, size_t StreamNumber, const String &Parameter, info_t KindOfInfo=Info_Text, info_t KindOfSearch=Info_Name); //Get info, FilePos=File position, StreamKind=General video audio text chapter, StreamNumber=stream number, PosInStream=parameter you want, KindOfInfo=name text measure options name(language) measure(language) information how to, KindOfSearch=which Kind Of information Parameter must be searched?
00120 
00121     //Set
00133     size_t Set (const String &ToSet, size_t FilePos, stream_t StreamKind, size_t StreamNumber, size_t Parameter, const String &OldValue=_T("")); //Get info, FilePos=File position, StreamKind=General video audio text chapter, StreamNumber=stream number, PosInStream=parameter you want, KindOfInfo=name, text, measure, options name(language) measure(language) information how to
00145     size_t Set (const String &ToSet, size_t FilePos, stream_t StreamKind, size_t StreamNumber, const String &Parameter, const String &OldValue=_T("")); //Get info, FilePos=File position, StreamKind=General video audio text chapter, StreamNumber=stream number, PosInStream=parameter you want, KindOfInfo=name text measure options name (language) measure (language) information how to, KindOfSearch=which Kind Of information Parameter must be searched?
00146 
00147     //Output_Buffered
00153     char* Output_Buffer_Get (size_t &Output_Buffer_Size);
00154 
00155     //Info
00161     String        Option (const String &Option, const String &Value=String(_T("")));
00167     static String Option_Static (const String &Option, const String &Value=String(_T("")));
00175     size_t                  State_Get ();
00181     size_t                  Count_Get (size_t FilePos, stream_t StreamKind, size_t StreamNumber=(size_t)-1);
00184     size_t                  Count_Get ();
00185 
00186 private :
00187     std::vector<MediaInfo*> Info;
00188     WxThread* Thread;
00189     int BlockMethod; //Open() return: 0=immedialtly, 1=after local info, 2=when user interaction is needed
00190 
00191 };
00192 
00193 } //NameSpace
00194 #endif

Generated on Mon Dec 10 14:07:11 2007 for MediaInfoLib by  doxygen 1.5.4