[ACR] Deprecate APIs that are difficult to use publicly
[platform/core/api/media-content.git] / include / media_info.h
index b5777fa..12bf5c1 100755 (executable)
@@ -918,6 +918,7 @@ int media_info_get_author(media_info_h media, char **author);
 int media_info_get_provider(media_info_h media, char **provider);
 
 /**
+ * @deprecated Deprecated since 4.0. Redundant, use media_info_get_display_name() instead.
  * @brief Gets the content name of content file which User set.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -936,7 +937,7 @@ int media_info_get_provider(media_info_h media, char **provider);
  *
  * @see media_info_set_content_name()
  */
-int media_info_get_content_name(media_info_h media, char **content_name);
+int media_info_get_content_name(media_info_h media, char **content_name) TIZEN_DEPRECATED_API;
 
 /**
  * @brief Gets the title of content file.
@@ -1024,6 +1025,7 @@ int media_info_get_location_tag(media_info_h media, char **location_tag);
 int media_info_get_age_rating(media_info_h media, char **age_rating);
 
 /**
+ * @deprecated Deprecated since 4.0. Use media_tag_insert_to_db() instead.
  * @brief Gets the keyword of content file which User set.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1042,7 +1044,7 @@ int media_info_get_age_rating(media_info_h media, char **age_rating);
  *
  * @see media_info_set_keyword()
  */
-int media_info_get_keyword(media_info_h media, char **keyword);
+int media_info_get_keyword(media_info_h media, char **keyword) TIZEN_DEPRECATED_API;
 
 /**
  * @brief Gets the storage id of content file.
@@ -1113,6 +1115,8 @@ int media_info_is_360_content(media_info_h media, bool *is_360);
 int media_info_get_storage_type(media_info_h media, media_content_storage_e *storage_type);
 
 /**
+ * @deprecated Deprecated since 4.0. \n
+ *        This function does not guarantee independence of the played count value between applications. It is recommended that the value is managed by the application.
  * @brief Gets number which represents how many times given content has been played.
  * @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif
  *
@@ -1125,9 +1129,11 @@ int media_info_get_storage_type(media_info_h media, media_content_storage_e *sto
  * @retval #MEDIA_CONTENT_ERROR_NONE Successful
  * @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter
  */
-int media_info_get_played_count(media_info_h media, int *played_count);
+int media_info_get_played_count(media_info_h media, int *played_count) TIZEN_DEPRECATED_API;
 
 /**
+ * @deprecated Deprecated since 4.0. \n
+ *        This function does not guarantee independence of the played time value between applications. It is recommended that the value is managed by the application.
  * @brief Gets the content's played time parameter.
  * @details Function returns content's elapsed playback time parameter as period
  *          starting from the beginning of the track.
@@ -1142,7 +1148,7 @@ int media_info_get_played_count(media_info_h media, int *played_count);
  * @retval #MEDIA_CONTENT_ERROR_NONE Successful
  * @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter
  */
-int media_info_get_played_time(media_info_h media, time_t *played_time);
+int media_info_get_played_time(media_info_h media, time_t *played_time) TIZEN_DEPRECATED_API;
 
 /**
  * @brief Gets the media info from the media database.
@@ -1172,6 +1178,8 @@ int media_info_get_played_time(media_info_h media, time_t *played_time);
 int media_info_get_media_from_db(const char *media_id, media_info_h *media);
 
 /**
+ * @deprecated Deprecated since 4.0. \n
+ *        This function does not guarantee independence of the played count value between applications. It is recommended that the value is managed by the application.
  * @brief Increments the played count to content meta handle.
  * @details You can increase the played(opened) count of the content file.
  * @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif
@@ -1186,9 +1194,11 @@ int media_info_get_media_from_db(const char *media_id, media_info_h *media);
  *
  * @post media_info_update_to_db()
  */
-int media_info_increase_played_count(media_info_h media);
+int media_info_increase_played_count(media_info_h media) TIZEN_DEPRECATED_API;
 
 /**
+ * @deprecated Deprecated since 4.0. \n
+ *        This function does not guarantee independence of the played time value between applications. It is recommended that the value is managed by the application.
  * @brief Sets the played time to content meta handle.
  * @details You can set the latest played(opened) time of the content file. the latest played time to be set the current time on the system.
  * @since_tizen @if MOBILE 2.4 @elseif WEARABLE 3.0 @endif
@@ -1203,9 +1213,10 @@ int media_info_increase_played_count(media_info_h media);
  *
  * @post media_info_update_to_db()
  */
-int media_info_set_played_time(media_info_h media);
+int media_info_set_played_time(media_info_h media) TIZEN_DEPRECATED_API;
 
 /**
+ * @deprecated Deprecated since 4.0. Redundant, use media_info_move_to_db() instead.
  * @brief Sets the file name including the extension of the content file.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1223,9 +1234,10 @@ int media_info_set_played_time(media_info_h media);
  * @post media_info_update_to_db().
  *
  */
-int media_info_set_display_name(media_info_h media, const char *display_name);
+int media_info_set_display_name(media_info_h media, const char *display_name) TIZEN_DEPRECATED_API;
 
 /**
+ * @deprecated Deprecated since 4.0. This data cannot be saved to the file.
  * @brief Sets the description of media info.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1243,9 +1255,10 @@ int media_info_set_display_name(media_info_h media, const char *display_name);
  * @post media_info_update_to_db().
  *
  */
-int media_info_set_description(media_info_h media, const char *description);
+int media_info_set_description(media_info_h media, const char *description) TIZEN_DEPRECATED_API;
 
 /**
+ * @deprecated Deprecated since 4.0. This data cannot be saved to the file.
  * @brief Sets the longitude of media info.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1262,9 +1275,10 @@ int media_info_set_description(media_info_h media, const char *description);
  *
  * @post media_info_update_to_db().
  */
-int media_info_set_longitude(media_info_h media, double longitude);
+int media_info_set_longitude(media_info_h media, double longitude) TIZEN_DEPRECATED_API;
 
 /**
+ * @deprecated Deprecated since 4.0. This data cannot be saved to the file.
  * @brief Sets the latitude of media info.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1281,9 +1295,10 @@ int media_info_set_longitude(media_info_h media, double longitude);
  *
  * @post media_info_update_to_db().
  */
-int media_info_set_latitude(media_info_h media, double latitude);
+int media_info_set_latitude(media_info_h media, double latitude) TIZEN_DEPRECATED_API;
 
 /**
+ * @deprecated Deprecated since 4.0. This data cannot be saved to the file.
  * @brief Sets the altitude of media info.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1300,7 +1315,7 @@ int media_info_set_latitude(media_info_h media, double latitude);
  *
  * @post media_info_update_to_db().
  */
-int media_info_set_altitude(media_info_h media, double altitude);
+int media_info_set_altitude(media_info_h media, double altitude) TIZEN_DEPRECATED_API;
 
 /**
  * @brief Sets the weather of media info.
@@ -1323,6 +1338,7 @@ int media_info_set_altitude(media_info_h media, double altitude);
 int media_info_set_weather(media_info_h media, const char *weather);
 
 /**
+ * @deprecated Deprecated since 4.0. This data cannot be saved to the file.
  * @brief Sets the rating of media info.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1339,7 +1355,7 @@ int media_info_set_weather(media_info_h media, const char *weather);
  *
  * @post media_info_update_to_db().
  */
-int media_info_set_rating(media_info_h media, int rating);
+int media_info_set_rating(media_info_h media, int rating) TIZEN_DEPRECATED_API;
 
 /**
  * @brief Sets the favorite of media info.
@@ -1364,6 +1380,7 @@ int media_info_set_rating(media_info_h media, int rating);
 int media_info_set_favorite(media_info_h media, bool favorite);
 
 /**
+ * @deprecated Deprecated since 4.0. This data cannot be saved to the file.
  * @brief Sets the author of media info.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1378,7 +1395,7 @@ int media_info_set_favorite(media_info_h media, bool favorite);
  * @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter
  * @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied
  */
-int media_info_set_author(media_info_h media, const char *author);
+int media_info_set_author(media_info_h media, const char *author) TIZEN_DEPRECATED_API;
 
 /**
  * @brief Sets the provider of media info.
@@ -1398,6 +1415,7 @@ int media_info_set_author(media_info_h media, const char *author);
 int media_info_set_provider(media_info_h media, const char *provider);
 
 /**
+ * @deprecated Deprecated since 4.0. Redundant, use media_info_move_to_db() instead.
  * @brief Sets the content name of media info.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1414,7 +1432,7 @@ int media_info_set_provider(media_info_h media, const char *provider);
  *
  * @post media_info_update_to_db()
  */
-int media_info_set_content_name(media_info_h media, const char *content_name);
+int media_info_set_content_name(media_info_h media, const char *content_name) TIZEN_DEPRECATED_API;
 
 /**
  * @brief Sets the category of media info.
@@ -1474,6 +1492,7 @@ int media_info_set_location_tag(media_info_h media, const char *location_tag);
 int media_info_set_age_rating(media_info_h media, const char *age_rating);
 
 /**
+ * @deprecated Deprecated since 4.0. Use media_tag_insert_to_db() instead.
  * @brief Sets the keyword of media info.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1490,7 +1509,7 @@ int media_info_set_age_rating(media_info_h media, const char *age_rating);
  *
  * @post media_info_update_to_db()
  */
-int media_info_set_keyword(media_info_h media, const char *keyword);
+int media_info_set_keyword(media_info_h media, const char *keyword) TIZEN_DEPRECATED_API;
 
 /**
  * @brief Updates the media info to the media database.
@@ -1502,7 +1521,7 @@ int media_info_set_keyword(media_info_h media, const char *keyword);
  * @privilege %http://tizen.org/privilege/content.write
  *
  * @remarks The function should be called after any change in media, to be updated to the media
- *          database. For example, after using media_info_set_display_name()
+ *          database. For example, after using media_info_set_favorite()
  *          for setting the name of the media, the media_info_update_to_db() function should be called so as to update
  *          the given media info attributes in the media database.
  *
@@ -1523,16 +1542,8 @@ int media_info_set_keyword(media_info_h media, const char *keyword);
  * @pre This function requires opened connection to content service by media_content_connect().
  *
  * @see media_content_connect()
- * @see media_info_set_display_name()
- * @see media_info_set_description()
- * @see media_info_set_longitude()
- * @see media_info_set_latitude()
- * @see media_info_set_altitude()
- * @see media_info_set_rating()
  * @see media_info_set_favorite()
- * @see media_info_set_author()
  * @see media_info_set_provider()
- * @see media_info_set_content_name()
  * @see media_info_set_category()
  * @see media_info_set_location_tag()
  * @see media_info_set_age_rating()
@@ -1540,6 +1551,7 @@ int media_info_set_keyword(media_info_h media, const char *keyword);
 int media_info_update_to_db(media_info_h media);
 
 /**
+ * @deprecated Deprecated since 4.0. Use media_content_scan_file() instead.
  * @brief Refreshes the media metadata to the media database.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1571,9 +1583,10 @@ int media_info_update_to_db(media_info_h media);
  *
  * @see media_content_connect()
  */
-int media_info_refresh_metadata_to_db(const char *media_id);
+int media_info_refresh_metadata_to_db(const char *media_id) TIZEN_DEPRECATED_API;
 
 /**
+ * @deprecated Deprecated since 4.0. This data cannot be saved to the file.
  * @brief Sets the added time of media info.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
@@ -1590,10 +1603,12 @@ int media_info_refresh_metadata_to_db(const char *media_id);
  *
  * @post media_info_update_to_db()
  */
-int media_info_set_added_time(media_info_h media, time_t added_time);
+int media_info_set_added_time(media_info_h media, time_t added_time) TIZEN_DEPRECATED_API;
 
 /**
  * @brief Moves the media info to the given destination path in the media database.
+ * @details After moving or renaming a file in the filesystem, call this function to update the database.
+ *
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
  *
  * @privlevel public
@@ -1624,6 +1639,7 @@ int media_info_set_added_time(media_info_h media, time_t added_time);
  * @pre This function requires opened connection to content service by media_content_connect().
  *
  * @see media_content_connect()
+ * @see media_content_scan_folder()
  */
 int media_info_move_to_db(media_info_h media, const char* dst_path);
 
@@ -1764,8 +1780,6 @@ int media_info_cancel_face_detection(media_info_h media);
 * @deprecated Deprecated since 4.0. Use media_info_insert_to_db() instead.
 * @brief Creates the media info handle.
 * @details If the information about the file that is already known, you can use this API to generate empty handler.
-*          And you can add the information to the generated handler using media_info_set_XXX() API.
-*          After filling the information to the handler, you can insert into database using media_info_insert_to_db_with_data() API.
 * @since_tizen 3.0
 *
 *
@@ -1787,7 +1801,6 @@ int media_info_cancel_face_detection(media_info_h media);
 * @retval #MEDIA_CONTENT_ERROR_DB_FAILED                DB operation failed
 * @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied
 *
-* @see media_info_insert_to_db_with_data()
 * @see media_info_destroy()
 */
 int media_info_create(const char *path, media_info_h *media) TIZEN_DEPRECATED_API;
@@ -1795,11 +1808,9 @@ int media_info_create(const char *path, media_info_h *media) TIZEN_DEPRECATED_AP
 /**
 * @deprecated Deprecated since 4.0. Use media_info_insert_to_db() instead.
 * @brief Inserts media info to database with media info data.
-* @details After filling the information to the generated handler using media_info_create() API, you can insert into database using this API.
 * @since_tizen 3.0
 *
-* @remarks You must create media handle using media_info_create(),
-*               and release @a info using media_info_destroy().
+* @remarks You must release @a info using media_info_destroy().
 *
 * @privlevel public
 * @privilege %http://tizen.org/privilege/content.write
@@ -1813,8 +1824,6 @@ int media_info_create(const char *path, media_info_h *media) TIZEN_DEPRECATED_AP
 * @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter
 * @retval #MEDIA_CONTENT_ERROR_DB_FAILED                DB operation failed
 * @retval #MEDIA_CONTENT_ERROR_PERMISSION_DENIED Permission denied
-*
-* @see media_info_create()
 */
 int media_info_insert_to_db_with_data(media_info_h media) TIZEN_DEPRECATED_API;
 
@@ -1831,8 +1840,6 @@ int media_info_insert_to_db_with_data(media_info_h media) TIZEN_DEPRECATED_API;
 *
 * @retval #MEDIA_CONTENT_ERROR_NONE Successful
 * @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter
-*
-* @post media_info_insert_to_db_with_data()
 */
 int media_info_set_title(media_info_h media, const char *title) TIZEN_DEPRECATED_API;
 
@@ -1849,8 +1856,6 @@ int media_info_set_title(media_info_h media, const char *title) TIZEN_DEPRECATED
 *
 * @retval #MEDIA_CONTENT_ERROR_NONE Successful
 * @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter
-*
-* @post media_info_insert_to_db_with_data()
 */
 int media_info_set_album(media_info_h media, const char *album) TIZEN_DEPRECATED_API;
 
@@ -1867,8 +1872,6 @@ int media_info_set_album(media_info_h media, const char *album) TIZEN_DEPRECATED
 *
 * @retval #MEDIA_CONTENT_ERROR_NONE Successful
 * @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter
-*
-* @post media_info_insert_to_db_with_data()
 */
 int media_info_set_artist(media_info_h media, const char *artist) TIZEN_DEPRECATED_API;
 
@@ -1885,8 +1888,6 @@ int media_info_set_artist(media_info_h media, const char *artist) TIZEN_DEPRECAT
 *
 * @retval #MEDIA_CONTENT_ERROR_NONE Successful
 * @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter
-*
-* @post media_info_insert_to_db_with_data()
 */
 int media_info_set_genre(media_info_h media, const char *genre) TIZEN_DEPRECATED_API;
 
@@ -1903,8 +1904,6 @@ int media_info_set_genre(media_info_h media, const char *genre) TIZEN_DEPRECATED
 *
 * @retval #MEDIA_CONTENT_ERROR_NONE Successful
 * @retval #MEDIA_CONTENT_ERROR_INVALID_PARAMETER Invalid parameter
-*
-* @post media_info_insert_to_db_with_data()
 */
 int media_info_set_recorded_date(media_info_h media, const char *recorded_date) TIZEN_DEPRECATED_API;