////////////////////////////////////////////////////////////////////////////////
FLAC::File::File(const char *file, bool readProperties,
- Properties::ReadStyle propertiesStyle) : TagLib::File(file)
+ Properties::ReadStyle propertiesStyle) :
+ TagLib::File(file)
{
d = new FilePrivate;
read(readProperties, propertiesStyle);
}
+FLAC::File::File(const char *file, ID3v2::FrameFactory *frameFactory,
+ bool readProperties, Properties::ReadStyle propertiesStyle) :
+ TagLib::File(file)
+{
+ d = new FilePrivate;
+ d->ID3v2FrameFactory = frameFactory;
+ read(readProperties, propertiesStyle);
+}
+
FLAC::File::~File()
{
delete d;
{
public:
/*!
- * Contructs an FLAC file from \a file. If \a readProperties is true the
+ * Contructs a FLAC file from \a file. If \a readProperties is true the
* file's audio properties will also be read using \a propertiesStyle. If
* false, \a propertiesStyle is ignored.
*/
File(const char *file, bool readProperties = true,
Properties::ReadStyle propertiesStyle = Properties::Average);
+ /*!
+ * Contructs a FLAC file from \a file. If \a readProperties is true the
+ * file's audio properties will also be read using \a propertiesStyle. If
+ * false, \a propertiesStyle is ignored.
+ *
+ * If this file contains and ID3v2 tag the frames will be created using
+ * \a frameFactory.
+ */
+ // BIC: merge with the above constructor
+ File(const char *file, ID3v2::FrameFactory *frameFactory,
+ bool readProperties = true,
+ Properties::ReadStyle propertiesStyle = Properties::Average);
+
/*!
* Destroys this instance of the File.
*/
// no ID3v2 tag exists and we've been asked to create one
- d->ID3v2Tag = new ID3v2::Tag();
+ d->ID3v2Tag = new ID3v2::Tag;
return d->ID3v2Tag;
}