![]() |
|
00001 /*************************************************************************** 00002 copyright : (C) 2002 by Scott Wheeler 00003 email : wheeler@kde.org 00004 ***************************************************************************/ 00005 00006 /*************************************************************************** 00007 * This library is free software; you can redistribute it and/or modify * 00008 * it under the terms of the GNU Lesser General Public License version * 00009 * 2.1 as published by the Free Software Foundation. * 00010 * * 00011 * This library is distributed in the hope that it will be useful, but * 00012 * WITHOUT ANY WARRANTY; without even the implied warranty of * 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * 00014 * Lesser General Public License for more details. * 00015 * * 00016 * You should have received a copy of the GNU Lesser General Public * 00017 * License along with this library; if not, write to the Free Software * 00018 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 * 00019 * USA * 00020 ***************************************************************************/ 00021 00022 #ifndef TAGLIB_VORBISFILE_H 00023 #define TAGLIB_VORBISFILE_H 00024 00025 #include <oggfile.h> 00026 #include <xiphcomment.h> 00027 00028 #include "vorbisproperties.h" 00029 00030 namespace TagLib { 00031 00032 /* 00033 * This is just to make this appear to be in the Ogg namespace in the 00034 * documentation. The typedef below will make this work with the current code. 00035 * In the next BIC version of TagLib this will be really moved into the Ogg 00036 * namespace. 00037 */ 00038 00039 #ifdef DOXYGEN 00040 namespace Ogg { 00041 #endif 00042 00044 00045 namespace Vorbis { 00046 00047 00049 00057 class File : public Ogg::File 00058 { 00059 public: 00065 File(const char *file, bool readProperties = true, 00066 Properties::ReadStyle propertiesStyle = Properties::Average); 00067 00071 virtual ~File(); 00072 00078 virtual Ogg::XiphComment *tag() const; 00079 00084 virtual Properties *audioProperties() const; 00085 00086 virtual bool save(); 00087 00088 private: 00089 File(const File &); 00090 File &operator=(const File &); 00091 00092 void read(bool readProperties, Properties::ReadStyle propertiesStyle); 00093 00094 class FilePrivate; 00095 FilePrivate *d; 00096 }; 00097 } 00098 00099 /* 00100 * To keep compatibility with the current version put Vorbis in the Ogg namespace 00101 * only in the docs and provide a typedef to make it work. In the next BIC 00102 * version this will be removed and it will only exist in the Ogg namespace. 00103 */ 00104 00105 #ifdef DOXYGEN 00106 } 00107 #else 00108 namespace Ogg { namespace Vorbis { typedef TagLib::Vorbis::File File; } } 00109 #endif 00110 00111 } 00112 00113 #endif