enum: move the position of the enum keys and apis related with the keys 66/41266/1 submit/tizen/20150612.073732
authortaeyoung <ty317.kim@samsung.com>
Fri, 12 Jun 2015 07:11:30 +0000 (16:11 +0900)
committertaeyoung <ty317.kim@samsung.com>
Fri, 12 Jun 2015 07:13:53 +0000 (16:13 +0900)
- The enum keys are deprecated, but Currently other apps use it.
  Thus the keys and apis are enabled now. The keys will be deprecated
  with "deprecated" flags

Change-Id: I0ecae4693e6db11c5803bda7450e3de64aa78440
Signed-off-by: taeyoung <ty317.kim@samsung.com>
include/system_info.h
include/system_info_private.h
include/system_info_type.h
src/system_info.c

index 8efbb5ecdd892bcf1feed96e3292c91470c7a2f1..555002965904d917ab53ef56220f57f810b987e4 100644 (file)
@@ -147,6 +147,29 @@ int system_info_get_custom_double(const char *key, double *value);
  */
 int system_info_get_custom_string(const char *key, char **value);
 
+/**
+ * @internal
+ * @brief Gets the integer value of the system information
+ */
+int system_info_get_value_int(system_info_key_e key, int *value);
+
+/**
+ * @internal
+ * @brief Gets the boolean value of the system information
+ */
+int system_info_get_value_bool(system_info_key_e key, bool *value);
+
+/**
+ * @internal
+ * @brief Gets the double value of the system information
+ */
+int system_info_get_value_double(system_info_key_e key, double *value);
+
+/**
+ * @internal
+ * @brief Gets the string value of the system information
+ */
+int system_info_get_value_string(system_info_key_e key, char **value);
 
 /**
  * @}
index 7aeebdbed3a8fc6cd50fce20483a45ec0a2faad2..5b3a6114d89487c02c324461aadc52bd8bd186e4 100644 (file)
@@ -46,27 +46,6 @@ extern "C"
 
 #define BOARD_CONFIG   "board"
 
-/**
- * @brief Enumeration of key for system information
- */
-typedef enum {
-       SYSTEM_INFO_KEY_MODEL,                  /**< The model of the device */
-       SYSTEM_INFO_KEY_TIZEN_VERSION,          /**< The version of the Tizen API */
-       SYSTEM_INFO_KEY_PLATFORM_NAME,          /**< The name of platform */
-       SYSTEM_INFO_KEY_TIZEN_VERSION_NAME,     /**< The name of tizen version  */
-       SYSTEM_INFO_KEY_MANUFACTURER,           /**< The manufacturer of the device */
-       SYSTEM_INFO_KEY_CORE_CPU_ARCH,          /**< The CORE CPU architecture of model */
-       SYSTEM_INFO_KEY_CORE_CPU_FREQ,          /**< The CORE CPU frequency of model */
-       SYSTEM_INFO_KEY_BUILD_STRING,           /**< The build string of platform binary */
-       SYSTEM_INFO_KEY_BUILD_DATE,             /**< The build date of platform binary */
-       SYSTEM_INFO_KEY_BUILD_TIME,             /**< The build time of platform binary */
-       SYSTEM_INFO_KEY_SCREEN_HEIGHT,          /**< The height of the screen in pixels */
-       SYSTEM_INFO_KEY_SCREEN_WIDTH,           /**< The width of the screen in pixels */
-       SYSTEM_INFO_KEY_PHYSICAL_SCREEN_HEIGHT, /**< The physical screen height in millimeters */
-       SYSTEM_INFO_KEY_PHYSICAL_SCREEN_WIDTH,  /**< The physical screen width in millimeters */
-       SYSTEM_INFO_KEY_TETHERING_SUPPORTED,    /**< Indicates whether the device supports tethering */
-} system_info_key_e;
-
 typedef enum {
        SYSTEM_INFO_DATA_TYPE_STRING,
        SYSTEM_INFO_DATA_TYPE_INT,
@@ -90,11 +69,6 @@ int system_info_ini_get_string(char *ini_file, char *key, char **output);
 int system_info_get_value_from_xml(char *xml_file_path, char *model, char *id_field, char **value);
 int system_info_get_value_from_config_xml(char *feature_tag, const char *name_field, char *type_field, char **value);
 
-int system_info_vconf_get_value_int(const char *vconf_key, int *value);
-int system_info_vconf_get_value_bool(const char *vconf_key, bool *value);
-int system_info_vconf_get_value_double(const char *vconf_key, double *value);
-int system_info_vconf_get_value_string(const char *vconf_key, char **value);
-
 int system_info_get_model(system_info_key_e key, system_info_data_type_e data_type, void **value);
 int system_info_get_tizen_version(system_info_key_e key, system_info_data_type_e data_type, void **value);
 int system_info_get_platform_name(system_info_key_e key, system_info_data_type_e data_type, void **value);
index 8aad0bd72c62a3b345aa7534c2b3aacb996bf90e..d9d16363972153cb7f493a612e56740da301aaf0 100644 (file)
@@ -41,6 +41,29 @@ typedef enum {
        SYSTEM_INFO_ERROR_PERMISSION_DENIED = TIZEN_ERROR_PERMISSION_DENIED, /**< No permission to use the API */
 } system_info_error_e;
 
+/**
+ * @internal
+ * @brief Enumeration of key for system information
+ */
+typedef enum {
+       SYSTEM_INFO_KEY_MODEL,                  /**< @internal The model of the device */
+       SYSTEM_INFO_KEY_TIZEN_VERSION,          /**< @internal The version of the Tizen API */
+       SYSTEM_INFO_KEY_PLATFORM_NAME,          /**< @internal The name of platform */
+       SYSTEM_INFO_KEY_TIZEN_VERSION_NAME,     /**< @internal The name of tizen version  */
+       SYSTEM_INFO_KEY_MANUFACTURER,           /**< @internal The manufacturer of the device */
+       SYSTEM_INFO_KEY_CORE_CPU_ARCH,          /**< @internal The CORE CPU architecture of model */
+       SYSTEM_INFO_KEY_CORE_CPU_FREQ,          /**< @internal The CORE CPU frequency of model */
+       SYSTEM_INFO_KEY_BUILD_STRING,           /**< @internal The build string of platform binary */
+       SYSTEM_INFO_KEY_BUILD_DATE,             /**< @internal The build date of platform binary */
+       SYSTEM_INFO_KEY_BUILD_TIME,             /**< @internal The build time of platform binary */
+       SYSTEM_INFO_KEY_SCREEN_HEIGHT,          /**< @internal The height of the screen in pixels */
+       SYSTEM_INFO_KEY_SCREEN_WIDTH,           /**< @internal The width of the screen in pixels */
+       SYSTEM_INFO_KEY_PHYSICAL_SCREEN_HEIGHT, /**< @internal The physical screen height in millimeters */
+       SYSTEM_INFO_KEY_PHYSICAL_SCREEN_WIDTH,  /**< @internal The physical screen width in millimeters */
+       SYSTEM_INFO_KEY_TETHERING_SUPPORTED,    /**< @internal Indicates whether the device supports tethering */
+} system_info_key_e;
+
+
 
 /**
  * @}
index ecbdd8fec0aec6ed08aac36ab4700265786d3b1f..f351984b894d78764e78514e0916d344fe025b5e 100644 (file)
@@ -239,6 +239,26 @@ int system_info_get_value(system_info_key_e key, system_info_data_type_e data_ty
        return system_info_getter(key, system_info->data_type, value);
 }
 
+API int system_info_get_value_int(system_info_key_e key, int *value)
+{
+       return system_info_get_value(key, SYSTEM_INFO_DATA_TYPE_INT, (void **)value);
+}
+
+API int system_info_get_value_bool(system_info_key_e key, bool *value)
+{
+       return system_info_get_value(key, SYSTEM_INFO_DATA_TYPE_BOOL, (void **)value);
+}
+
+API int system_info_get_value_double(system_info_key_e key, double *value)
+{
+       return system_info_get_value(key, SYSTEM_INFO_DATA_TYPE_DOUBLE, (void **)value);
+}
+
+API int system_info_get_value_string(system_info_key_e key, char **value)
+{
+       return system_info_get_value(key, SYSTEM_INFO_DATA_TYPE_STRING, (void **)value);
+}
+
 API int system_info_get_platform_bool(const char *key, bool *value)
 {
        int ret;