]> granicus.if.org Git - taglib/commitdiff
Some extra documentation.
authorAllan Sandfeld Jensen <kde@carewolf.com>
Mon, 23 Aug 2004 21:57:07 +0000 (21:57 +0000)
committerAllan Sandfeld Jensen <kde@carewolf.com>
Mon, 23 Aug 2004 21:57:07 +0000 (21:57 +0000)
git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/kdesupport/taglib@340248 283d02a7-25f6-0310-bc7c-ecb5cbfe19da

ape/apeitem.h

index a450f01f7e2878acd94c31dd16b3b743d5f5d589..ee2b67338191011a6073155b4139277230c5df78 100644 (file)
@@ -37,44 +37,96 @@ namespace TagLib {
      */
     struct Item
     {
+      /*!
+       * Enum of types an Item can have. The value of 3 is reserved.
+       */
       enum ItemTypes {
-        //! Item contains text information coded in UTF-8
+        //! item contains text information coded in UTF-8
         Text = 0,
-        //! Item contains binary information
+        //! item contains binary information
         Binary = 1,
-        //! Item is a locator of external stored information
+        //! item is a locator of external stored information
         Locator = 2
       };
+      /*!
+       * Constructs an empty item.
+       */
       Item();
-      explicit Item(ByteVector& bin);
-      explicit Item(const String&, const String&);
-      explicit Item(const String&, const StringList &);
+
+      /*!
+       * Constructs an item with \a key and \a value.
+       */
+      Item(const String& key, const String& value);
+
+      /*!
+       * Constructs an item with \a key and \a values.
+       */
+      Item(const String& key, const StringList& values);
+
       Item(const Item&);
       Item& operator=(const Item&);
 
+      /*!
+       * Returns the key
+       */
       String key() const;
+
+      /*!
+       * Returns the binary value
+       */
       ByteVector value() const;
 
+      /*!
+       * Returns the size of the full item
+       */
       int size() const;
 
+      /*!
+       * Returns the value as a single string. In case of multiple strings,
+       * the first is returned.
+       */
       String toString() const;
+
+      /*!
+       * Returns the value as a string list.
+       */
       StringList toStringList() const;
 
+      /*!
+       * Render the item to a ByteVector
+       */
       ByteVector render();
-      void parse(const ByteVector&);
 
+      /*!
+       * Parse the item from the ByteVector \a data
+       */
+      void parse(const ByteVector& data);
+
+      /*!
+       * Set the item to read-only
+       */
       void setReadOnly(bool);
 
+      /*!
+       * Returns if the item is read-only
+       */
       bool isReadOnly() const;
 
+      /*!
+       * Sets the type of the item to \a type.
+       *
+       * \see ItemTypes
+       */
       void setType(ItemTypes type);
 
+      /*!
+       * Returns the type of the item.
+       */
       ItemTypes type() const;
-/*
-      void setValue(ByteVector);
-      void setValue(const String&);
-      void setValue(const StringList&);
- */
+
+      /*!
+       * Returns if the item has any real content.
+       */
       bool isEmpty() const;
 
     private: