Implementation of ImmutableString
[platform/framework/native/appfw.git] / inc / FBaseColIMap.h
index c5b161d..01faca3 100644 (file)
@@ -1,5 +1,4 @@
 //
-// Open Service Platform
 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
 //
 // Licensed under the Apache License, Version 2.0 (the License);
@@ -29,7 +28,6 @@
 #include <FBaseColIMapEnumerator.h>
 #include <FBaseObject.h>
 
-
 namespace Tizen { namespace Base { namespace Collection
 {
 
@@ -37,8 +35,8 @@ class IList;
 class MapEntry;
 
 /**
- * @interface IMap
- * @brief      This interface represents a collection of key-value pairs.
+ * @interface  IMap
+ * @brief              This interface represents a collection of key-value pairs.
  *
  * @since 2.0
  *
@@ -114,7 +112,7 @@ public:
         * @exception   E_INVALID_ARG           A specified input parameter is invalid, or
         *                                                                      the comparer has failed to compare the keys.
         * @remarks     This method performs a shallow copy. It adds just the pointer; not the element itself.
-        * @see                 Add()
+        * @see                 Add(Object*, Object*)
         * @see                 SetValue()
         */
        result AddIfNotExistOrSet(Object* pKey, Object* pValue)
@@ -136,7 +134,7 @@ public:
         *
         * @return              The value associated with the specified key, @n
         *                              else @c null if an exception occurs
-        * @param[in]   key     The key to find the associated value
+        * @param[in]   key                             The key to find the associated value
         * @exception   E_SUCCESS               The method is successful.
         * @exception   E_INVALID_ARG   The specified input parameter is invalid, or
         *                                                              the comparer has failed to compare the keys.
@@ -153,7 +151,7 @@ public:
         *
         * @return              The value associated with the specified key, @n
         *                              else @c null if an exception occurs
-        * @param[in]   key     The key to find the associated value
+        * @param[in]   key                             The key to find the associated value
         * @exception   E_SUCCESS               The method is successful.
         * @exception   E_INVALID_ARG   The specified input parameter is invalid, or
         *                                                              the comparer has failed to compare the keys.
@@ -170,9 +168,10 @@ public:
         *
         * @return              A pointer to a list of all the keys in the map, @n
         *                              else @c null if an exception occurs
-        * @remarks             The order of the keys is the same as the corresponding values in the IList interface returned by the GetValuesN() method.
-        * @remarks             The %IList interface stores just the pointers to the elements in the map, not the elements themselves.
-        * @remarks             The specific error code can be accessed using the GetLastResult() method.
+        * @remarks
+        *                              - The order of the keys is the same as the corresponding values in the IList interface returned by the GetValuesN() method.
+        *                              - The %IList interface stores just the pointers to the elements in the map, not the elements themselves.
+        *                              - The specific error code can be accessed using the GetLastResult() method.
         * @see                 GetValuesN()
         */
        virtual IList* GetKeysN(void) const = 0;
@@ -184,8 +183,9 @@ public:
         *
         * @return              A pointer to a list of all the values in the map, @n
         *                              else @c null if an exception occurs
-        * @remarks             The IList stores just the pointers to the elements in the map, not the elements themselves.
-        * @remarks             The specific error code can be accessed using the GetLastResult() method.
+        * @remarks
+        *                              - The IList stores just the pointers to the elements in the map, not the elements themselves.
+        *                              - The specific error code can be accessed using the GetLastResult() method.
         * @see                 GetKeysN()
         */
        virtual IList* GetValuesN(void) const = 0;
@@ -198,29 +198,30 @@ public:
         * @return              An error code
         * @param[in]   key The key to remove
         * @param[in]   forceDeletion           Set to @c true to deallocate the object, @n
-        *                                                              else @c false
+        *                                                                      else @c false
         * @exception   E_SUCCESS               The method is successful.
         * @exception   E_INVALID_ARG   A specified input parameter is invalid, or
         *                                                              the comparer has failed to compare the keys.
         * @exception   E_OBJ_NOT_FOUND The specified @c key is not found in the map.
-        * @remarks             Based on the specified element deleter, the remove operation not only gets rid of an element from a list, but also deletes its object instance. @n
+        * @remarks
+        *                              - Based on the specified element deleter, the remove operation not only gets rid of an element from a list, but also deletes its object instance. @n
         *                              The element deleter style is recommended rather than using the @c forceDeletetion argument in the remove method. @n
         *                              If both an element deleter and forceDeleteion are set, the remove operation follows @c forceDeletion setting.
-        * @remarks             Remove(key, @b true) internally works as the below code:
+        *                              - Remove(key, @b true) internally works as the below code:
         * @code
         * DeleterFunctionType deleter = GetDeleter();
         * SetDeleter(SingleObjectDeleter);
         * Remove(key);
         * SetDeleter(deleter);
         * @endcode
-        * @remarks             Remove(key, @b false) internally works as the below code:
+        *                              - Remove(key, @b false) internally works as the below code:
         * @code
         * DeleterFunctionType deleter = GetDeleter();
         * SetDeleter(NoOpDeleter);
         * Remove(key);
         * SetDeleter(deleter);
         * @endcode
-        * @see                 Add()
+        * @see                 Add(Object*, Object*)
         */
        result Remove(const Object& key, bool forceDeletion)
        {
@@ -246,12 +247,12 @@ public:
         * @since 2.0
         *
         * @return              An error code
-        * @param[in]   key The key for which the value is to remove
+        * @param[in]   key                             The key for which the value is to remove
         * @exception   E_SUCCESS               The method is successful.
         * @exception   E_INVALID_ARG   A specified input parameter is invalid, or
         *                                                              the comparer has failed to compare the keys.
         * @exception   E_OBJ_NOT_FOUND The specified @c key is not found in the map.
-        * @see                 Add()
+        * @see                 Add(Object*, Object*)
         */
        virtual result Remove(const Object& key) = 0;
 
@@ -262,18 +263,19 @@ public:
         * @since 2.0
         *
         * @param[in]   forceDeletion           Set to @c true to deallocate all the objects, @n
-        *                                                              else @c false
-        * @remarks             Based on the specified element deleter, the remove operation not only gets rid of an element from a list, but also deletes its object instance. @n
+        *                                                                      else @c false
+        * @remarks
+        *                              - Based on the specified element deleter, the remove operation not only gets rid of an element from a list, but also deletes its object instance. @n
         *                              The element deleter style is recommended rather than using the @c forceDeletetion argument in the remove method. @n
         *                              If both an element deleter and forceDeleteion are set, the remove operation follows @c forceDeletion setting.
-        * @remarks             RemoveAll(@b true) internally works as the below code:
+        *                              - RemoveAll(@b true) internally works as the below code:
         * @code
         * DeleterFunctionType deleter = GetDeleter();
         * SetDeleter(SingleObjectDeleter);
         * RemoveAll();
         * SetDeleter(deleter);
         * @endcode
-        * @remarks             RemoveAll(@b false) internally works as the below code:
+        *                              - RemoveAll(@b false) internally works as the below code:
         * @code
         * DeleterFunctionType deleter = GetDeleter();
         * SetDeleter(NoOpDeleter);
@@ -311,33 +313,33 @@ public:
         * @since 2.0
         *
         * @return              An error code
-        * @param[in]   key     The key for which the value is to replace
-        * @param[in]   value   The new value
+        * @param[in]   key     The key for which the value is to replace
+        * @param[in]   value   The new value
         * @param[in]   forceDeletion           Set to @c true to deallocate the object, @n
-        *                                                              else @c false
+        *                                                                      else @c false
         * @exception   E_SUCCESS               The method is successful.
         * @exception   E_INVALID_ARG   A specified input parameter is invalid, or
         *                                                              the comparer has failed to compare the keys.
         * @exception   E_OBJ_NOT_FOUND The specified @c key is not found in the map.
-        * @remarks     Use the Add() method to add a new key-value pair.
-        * @remarks             Based on the specified element deleter, the set operation not only gets rid of an element from a list, but also deletes its object instance. @n
-        *                              The element deleter style is recommended rather than using the @c forceDeletetion argument in the set method. @n
-        *                              If both an element deleter and forceDeleteion are set, the set operation follows @c forceDeletion setting.
-        * @remarks     SetValue(key, value, @b true) internally works as the below code:
+        * @remarks
+        *                      - Use the Add(Object*, Object*) method to add a new key-value pair.
+        *                      - Based on the specified element deleter, the set operation not only gets rid of an element from a list, but also deletes its object instance. @n
+        *                      The element deleter style is recommended rather than using the @c forceDeletetion argument in the set method. @n
+        *                      If both an element deleter and forceDeleteion are set, the set operation follows @c forceDeletion setting.
+        *                      - SetValue(key, value, @b true) internally works as the below code:
         * @code
         * DeleterFunctionType deleter = GetDeleter();
         * SetDeleter(SingleObjectDeleter);
         * SetValue(key, const_cast< Object* >(&value));
         * SetDeleter(deleter);
         * @endcode
-        * @remarks     SetValue(key, value, @b false) internally works as the below code:
+        *                      - SetValue(key, value, @b false) internally works as the below code:
         * @code
         * DeleterFunctionType deleter = GetDeleter();
         * SetDeleter(NoOpDeleter);
         * SetValue(key, const_cast< Object* >(&value));
         * SetDeleter(deleter);
         * @endcode
-        * @see         Add()
         * @see         GetValue()
         */
        result SetValue(const Object& key, const Object& value, bool forceDeletion = false)
@@ -364,15 +366,14 @@ public:
         * @since 2.0
         *
         * @return              An error code
-        * @param[in] key               The key for which the value is to replace
+        * @param[in]   key             The key for which the value is to replace
         * @param[in]   pValue  The pointer to new value
         * @exception   E_SUCCESS               The method is successful.
         * @exception   E_INVALID_ARG   A specified input parameter is invalid, or
         *                                                              the comparer has failed to compare the keys.
         * @exception   E_OBJ_NOT_FOUND The specified @c key is not found in the map.
-        * @remarks     Use the Add() method to add a new key-value pair.
-        * @see         Add()
-        * @see         GetValue()
+        * @remarks             Use the Add(Object*, Object*) method to add a new key-value pair.
+        * @see                 GetValue()
         */
        virtual result SetValue(const Object& key, Object* pValue) = 0;
 
@@ -410,7 +411,7 @@ public:
         *
         * @return              @c true if the map contains the specified key, @n
         *                              else @c false
-        * @param[in]   key     The key to locate
+        * @param[in]   key                     The key to locate
         * @exception   E_SUCCESS               The method is successful.
         * @exception   E_INVALID_ARG   A specified input parameter is invalid, or
         *                                                              the comparer has failed to compare the keys.
@@ -428,7 +429,7 @@ public:
         *                              else @c false
         * @param[in]   value   The value to locate
         *
-        * @see                 ContainsKey()
+        * @see                 ContainsKey(const Object&)
         */
        virtual bool ContainsValue(const Object& value) const = 0;
 
@@ -437,7 +438,7 @@ public:
        *
        * @since 2.0
        *
-       * @return                       IMapEnumerator object of this map, @n
+       * @return               IMapEnumerator object of this map, @n
        *                               else @c null if an exception occurs
        * @exception    E_SUCCESS               The method is successful.
        * @remarks              The specific error code can be accessed using the GetLastResult() method.
@@ -465,7 +466,6 @@ protected:
        //
        virtual void IMap_Reserved1(void) { }
 
-
        //
        // This method is for internal use only. Using this method can cause behavioral, security-related,
        // and consistency-related issues in the application.