From ec15dfdd462f297ee0be9040c41d5c8f29ae9115 Mon Sep 17 00:00:00 2001 From: Joohyun Kim Date: Mon, 10 Jun 2013 16:55:49 +0900 Subject: [PATCH] Add comment on Battery Class and move internal header Change-Id: I43a8545988160e9bf6902a72c63e70f1fd17e341 Signed-off-by: Joohyun Kim --- inc/FSysBattery.h | 64 ++++++++++++++++++++++++++++++++- src/system-server/inc/FSys_SystemInfo.h | 14 ++++++++ 2 files changed, 77 insertions(+), 1 deletion(-) create mode 100644 src/system-server/inc/FSys_SystemInfo.h diff --git a/inc/FSysBattery.h b/inc/FSysBattery.h index b05c822..4e9bef7 100644 --- a/inc/FSysBattery.h +++ b/inc/FSysBattery.h @@ -34,7 +34,6 @@ namespace Tizen { namespace System /** * @if OSPCOMPAT - * @if OSPDEPREC * @class Battery * @brief [Deprecated] This class provides methods to get information related to the battery charge. * @@ -49,54 +48,117 @@ namespace Tizen { namespace System * * For more information on the class features, see Battery Status. * @endif + */ + +/** + * @if OSPCOMPAT + * @page CompGetCurrentLevelInPercentage Compatibility for current battery level + * @section CompGetCurrentLevelInPercentageIssue Issues + * Implementation of this method in %Tizen API versions prior to 2.1 has the following issue: @n + * + * -# GetCurrentLevelInPercentage() is moved to PowerManager class. + * + * @section CompGetCurrentLevelInPercentageResolution Resolutions + * The issue mentioned above is resolved in %Tizen API version 2.1 as follows: @n + * + * -# GetCurrentLevelInPercentage() is provided by PowerManager class. + * @endif + */ + +/** + * @if OSPCOMPAT + * @page CompGetCurrentLevel Compatibility for current battery level + * @section CompGetCurrentLevelIssue Issues + * Implementation of this method in %Tizen API versions prior to 2.1 has the following issue: @n + * + * -# CompGetCurrentLevel() is moved to PowerManager class. + * + * @section CompGetCurrentLevelResolution Resolutions + * The issue mentioned above is resolved in %Tizen API version 2.1 as follows: @n + * + * -# GetCurrentLevel() is supported by PowerManager class. + * @endif + */ + +/** + * @if OSPCOMPAT + * @page CompIsCharging Compatibility for current battery level + * @section CompIsChargingIssue Issues + * Implementation of this method in %Tizen API versions prior to 2.1 has the following issue: @n + * + * -# IsCharging() is moved to PowerManager class. + * + * @section CompIsChargingResolution Resolutions + * The issue mentioned above is resolved in %Tizen API version 2.1 as follows: @n + * + * -# IsCharging() is supported by PowerManager class. * @endif */ + class _OSP_EXPORT_ Battery : public Tizen::Base::Object { public: /** + * @if OSPCOMPAT + * @if OSPDEPREC * Gets the current charge remaining in the battery as a percentage. * * @deprecated This method is deprecated. Instead of using this method, use the PowerManager::GetCurrentBatteryLevelInPercentage() method. * @since 2.0 * + * @compatibility This method has compatibility issues with OSP compatible applications. @n + * For more information, see @ref CompGetCurrentLevelInPercentage "here". * @return An error code * @param[out] level The percentage of the charge remaining in the battery * @exception E_SUCCESS The method is successful. * @exception E_INVALID_STATE The battery service is not available. * @exception E_SYSTEM The method cannot proceed due to a severe system error. * @remarks The resolution of the level is @c 1% since 2.0. The range of the level is @c 0 (Minimum) to @c 100 (Maximum). + * @endif + * @endif */ static result GetCurrentLevelInPercentage(int& level); /** + * @if OSPCOMPAT + * @if OSPDEPREC * Gets the current charging level of the battery. * * @deprecated This method is deprecated. Instead of using this method, use the PowerManager::GetCurrentBatteryLevel() method. * @since 2.0 * + * @compatibility This method has compatibility issues with OSP compatible applications. @n + * For more information, see @ref CompGetCurrentLevel "here". * @return An error code * @param[out] level A value from the enumerator BatteryLevel indicating the current charging level * @exception E_SUCCESS The method is successful. * @exception E_INVALID_STATE The battery service is not available. * @exception E_SYSTEM The method cannot proceed due to a severe system error. + * @endif + * @endif */ static result GetCurrentLevel(BatteryLevel& level); /** + * @if OSPCOMPAT + * @if OSPDEPREC * Checks whether the battery is currently charging. * * @deprecated This method is deprecated. Instead of using this method, use the PowerManager::IsCharging() method. * @since 2.0 * + * @compatibility This method has compatibility issues with OSP compatible applications. @n + * For more information, see @ref CompIsCharging "here". * @return An error code * @param[out] charging Set to @c true if the charging cable is connected to the phone, @n * else @c false * @exception E_SUCCESS The method is successful. * @exception E_INVALID_STATE The battery service is not available. * @exception E_SYSTEM The method cannot proceed due to a severe system error. + * @endif + * @endif */ static result IsCharging(bool& charging); diff --git a/src/system-server/inc/FSys_SystemInfo.h b/src/system-server/inc/FSys_SystemInfo.h new file mode 100644 index 0000000..fe8200e --- /dev/null +++ b/src/system-server/inc/FSys_SystemInfo.h @@ -0,0 +1,14 @@ +#ifndef _FSYS_SYSTEM_INFO_H_ +#define _FSYS_SYSTEM_INFO_H_ + +namespace Tizen { namespace System +{ +class _SystemInfo +{ +public: + _SystemInfo(); + ~_SystemInfo(); +}; + +}} +#endif -- 2.7.4