TagLib 1.5 (TagLib: generalencapsulatedobjectframe.h Source File)

generalencapsulatedobjectframe.h

Go to the documentation of this file.
00001 /***************************************************************************
00002     copyright            : (C) 2002 - 2008 by Scott Wheeler
00003     email                : wheeler@kde.org
00004     copyright            : (C) 2006 by Aaron VonderHaar
00005     email                : avh4@users.sourceforge.net
00006  ***************************************************************************/
00007 
00008 /***************************************************************************
00009  *   This library is free software; you can redistribute it and/or modify  *
00010  *   it under the terms of the GNU Lesser General Public License version   *
00011  *   2.1 as published by the Free Software Foundation.                     *
00012  *                                                                         *
00013  *   This library is distributed in the hope that it will be useful, but   *
00014  *   WITHOUT ANY WARRANTY; without even the implied warranty of            *
00015  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU     *
00016  *   Lesser General Public License for more details.                       *
00017  *                                                                         *
00018  *   You should have received a copy of the GNU Lesser General Public      *
00019  *   License along with this library; if not, write to the Free Software   *
00020  *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  *
00021  *   USA                                                                   *
00022  *                                                                         *
00023  *   Alternatively, this file is available under the Mozilla Public        *
00024  *   License Version 1.1.  You may obtain a copy of the License at         *
00025  *   http://www.mozilla.org/MPL/                                           *
00026  ***************************************************************************/
00027 
00028 #ifndef TAGLIB_GENERALENCAPSULATEDOBJECT_H
00029 #define TAGLIB_GENERALENCAPSULATEDOBJECT_H
00030 
00031 #include <id3v2frame.h>
00032 #include <id3v2header.h>
00033 #include "taglib_export.h"
00034 
00035 namespace TagLib {
00036 
00037   namespace ID3v2 {
00038 
00040 
00050     class TAGLIB_EXPORT GeneralEncapsulatedObjectFrame : public Frame
00051     {
00052       friend class FrameFactory;
00053 
00054     public:
00055 
00060       GeneralEncapsulatedObjectFrame();
00061 
00065       explicit GeneralEncapsulatedObjectFrame(const ByteVector &data);
00066 
00070       virtual ~GeneralEncapsulatedObjectFrame();
00071 
00075       virtual String toString() const;
00076 
00084       String::Type textEncoding() const;
00085 
00092       void setTextEncoding(String::Type encoding);
00093 
00097       String mimeType() const;
00098 
00102       void setMimeType(const String &type);
00103 
00109       String fileName() const;
00110 
00116       void setFileName(const String &name);
00117 
00126       String description() const;
00127 
00136       void setDescription(const String &desc);
00137 
00147       ByteVector object() const;
00148 
00157       void setObject(const ByteVector &object);
00158 
00159     protected:
00160       virtual void parseFields(const ByteVector &data);
00161       virtual ByteVector renderFields() const;
00162 
00163     private:
00164       GeneralEncapsulatedObjectFrame(const ByteVector &data, Header *h);
00165       GeneralEncapsulatedObjectFrame(const GeneralEncapsulatedObjectFrame &);
00166       GeneralEncapsulatedObjectFrame &operator=(const GeneralEncapsulatedObjectFrame &);
00167 
00168       class GeneralEncapsulatedObjectFramePrivate;
00169       GeneralEncapsulatedObjectFramePrivate *d;
00170     };
00171   }
00172 }
00173 
00174 #endif