summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJosh Coalson <jcoalson@users.sourceforce.net>2005-01-07 01:09:07 +0000
committerJosh Coalson <jcoalson@users.sourceforce.net>2005-01-07 01:09:07 +0000
commit42372b9aedf313ae5d5ab1ad16d0cde09b6dffe4 (patch)
tree9a30f1f278bf48bd158aee619c8901d010ede1ea /include
parent1518d94101d8a91093625a06016003094df9c28a (diff)
downloadflac-42372b9aedf313ae5d5ab1ad16d0cde09b6dffe4.tar.gz
libFLAC++: all metadata object operator=() funcs now return *this; add Metadata::*::assign() and FLAC::Metadata::get_tags()
Diffstat (limited to 'include')
-rw-r--r--include/FLAC++/metadata.h93
1 files changed, 67 insertions, 26 deletions
diff --git a/include/FLAC++/metadata.h b/include/FLAC++/metadata.h
index f4a217b8..17d7dd54 100644
--- a/include/FLAC++/metadata.h
+++ b/include/FLAC++/metadata.h
@@ -126,11 +126,16 @@ namespace FLAC {
//@{
/** Assign from another object. Always performs a deep copy. */
- void operator=(const Prototype &);
- void operator=(const ::FLAC__StreamMetadata &);
- void operator=(const ::FLAC__StreamMetadata *);
+ Prototype &operator=(const Prototype &);
+ Prototype &operator=(const ::FLAC__StreamMetadata &);
+ Prototype &operator=(const ::FLAC__StreamMetadata *);
//@}
+ /** Assigns an object with copy control. See
+ * Prototype(::FLAC__StreamMetadata *object, bool copy).
+ */
+ Prototype &assign_object(::FLAC__StreamMetadata *object, bool copy);
+
/** Deletes the underlying ::FLAC__StreamMetadata object.
*/
virtual void clear();
@@ -278,11 +283,16 @@ namespace FLAC {
//@{
/** Assign from another object. Always performs a deep copy. */
- inline void operator=(const StreamInfo &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); }
+ inline StreamInfo &operator=(const StreamInfo &object) { Prototype::operator=(object); return *this; }
+ inline StreamInfo &operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); return *this; }
+ inline StreamInfo &operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); return *this; }
//@}
+ /** Assigns an object with copy control. See
+ * Prototype::assign_object(::FLAC__StreamMetadata *object, bool copy).
+ */
+ inline StreamInfo &assign(::FLAC__StreamMetadata *object, bool copy) { Prototype::assign_object(object, copy); return *this; }
+
//@{
/** Check for equality, performing a deep compare by following pointers. */
inline bool operator==(const StreamInfo &object) const { return Prototype::operator==(object); }
@@ -346,11 +356,16 @@ namespace FLAC {
//@{
/** Assign from another object. Always performs a deep copy. */
- inline void operator=(const Padding &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); }
+ inline Padding &operator=(const Padding &object) { Prototype::operator=(object); return *this; }
+ inline Padding &operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); return *this; }
+ inline Padding &operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); return *this; }
//@}
+ /** Assigns an object with copy control. See
+ * Prototype::assign_object(::FLAC__StreamMetadata *object, bool copy).
+ */
+ inline Padding &assign(::FLAC__StreamMetadata *object, bool copy) { Prototype::assign_object(object, copy); return *this; }
+
//@{
/** Check for equality, performing a deep compare by following pointers. */
inline bool operator==(const Padding &object) const { return Prototype::operator==(object); }
@@ -393,11 +408,16 @@ namespace FLAC {
//@{
/** Assign from another object. Always performs a deep copy. */
- inline void operator=(const Application &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); }
+ inline Application &operator=(const Application &object) { Prototype::operator=(object); return *this; }
+ inline Application &operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); return *this; }
+ inline Application &operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); return *this; }
//@}
+ /** Assigns an object with copy control. See
+ * Prototype::assign_object(::FLAC__StreamMetadata *object, bool copy).
+ */
+ inline Application &assign(::FLAC__StreamMetadata *object, bool copy) { Prototype::assign_object(object, copy); return *this; }
+
//@{
/** Check for equality, performing a deep compare by following pointers. */
inline bool operator==(const Application &object) const { return Prototype::operator==(object); }
@@ -446,11 +466,16 @@ namespace FLAC {
//@{
/** Assign from another object. Always performs a deep copy. */
- inline void operator=(const SeekTable &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); }
+ inline SeekTable &operator=(const SeekTable &object) { Prototype::operator=(object); return *this; }
+ inline SeekTable &operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); return *this; }
+ inline SeekTable &operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); return *this; }
//@}
+ /** Assigns an object with copy control. See
+ * Prototype::assign_object(::FLAC__StreamMetadata *object, bool copy).
+ */
+ inline SeekTable &assign(::FLAC__StreamMetadata *object, bool copy) { Prototype::assign_object(object, copy); return *this; }
+
//@{
/** Check for equality, performing a deep compare by following pointers. */
inline bool operator==(const SeekTable &object) const { return Prototype::operator==(object); }
@@ -527,7 +552,7 @@ namespace FLAC {
Entry(const Entry &entry);
- void operator=(const Entry &entry);
+ Entry &operator=(const Entry &entry);
virtual ~Entry();
@@ -588,11 +613,16 @@ namespace FLAC {
//@{
/** Assign from another object. Always performs a deep copy. */
- inline void operator=(const VorbisComment &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); }
+ inline VorbisComment &operator=(const VorbisComment &object) { Prototype::operator=(object); return *this; }
+ inline VorbisComment &operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); return *this; }
+ inline VorbisComment &operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); return *this; }
//@}
+ /** Assigns an object with copy control. See
+ * Prototype::assign_object(::FLAC__StreamMetadata *object, bool copy).
+ */
+ inline VorbisComment &assign(::FLAC__StreamMetadata *object, bool copy) { Prototype::assign_object(object, copy); return *this; }
+
//@{
/** Check for equality, performing a deep compare by following pointers. */
inline bool operator==(const VorbisComment &object) const { return Prototype::operator==(object); }
@@ -645,7 +675,7 @@ namespace FLAC {
Track();
Track(const ::FLAC__StreamMetadata_CueSheet_Track *track);
Track(const Track &track);
- void operator=(const Track &track);
+ Track &operator=(const Track &track);
virtual ~Track();
@@ -693,11 +723,16 @@ namespace FLAC {
//@{
/** Assign from another object. Always performs a deep copy. */
- inline void operator=(const CueSheet &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); }
+ inline CueSheet &operator=(const CueSheet &object) { Prototype::operator=(object); return *this; }
+ inline CueSheet &operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); return *this; }
+ inline CueSheet &operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); return *this; }
//@}
+ /** Assigns an object with copy control. See
+ * Prototype::assign_object(::FLAC__StreamMetadata *object, bool copy).
+ */
+ inline CueSheet &assign(::FLAC__StreamMetadata *object, bool copy) { Prototype::assign_object(object, copy); return *this; }
+
//@{
/** Check for equality, performing a deep compare by following pointers. */
inline bool operator==(const CueSheet &object) const { return Prototype::operator==(object); }
@@ -771,11 +806,16 @@ namespace FLAC {
//@{
/** Assign from another object. Always performs a deep copy. */
- inline void operator=(const Unknown &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); }
- inline void operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); }
+ inline Unknown &operator=(const Unknown &object) { Prototype::operator=(object); return *this; }
+ inline Unknown &operator=(const ::FLAC__StreamMetadata &object) { Prototype::operator=(object); return *this; }
+ inline Unknown &operator=(const ::FLAC__StreamMetadata *object) { Prototype::operator=(object); return *this; }
//@}
+ /** Assigns an object with copy control. See
+ * Prototype::assign_object(::FLAC__StreamMetadata *object, bool copy).
+ */
+ inline Unknown &assign(::FLAC__StreamMetadata *object, bool copy) { Prototype::assign_object(object, copy); return *this; }
+
//@{
/** Check for equality, performing a deep compare by following pointers. */
inline bool operator==(const Unknown &object) const { return Prototype::operator==(object); }
@@ -817,6 +857,7 @@ namespace FLAC {
//! See FLAC__metadata_get_tags().
FLACPP_API bool get_tags(const char *filename, VorbisComment *&tags);
+ FLACPP_API bool get_tags(const char *filename, VorbisComment &tags);
/* \} */