android 系统使用c语言获取系统属性

时间:2014-12-24 09:45:28   收藏:0   阅读:417

1. 包含bionic库中"sys/system_properties.h" 

2. 使用接口

a:获取接口 int _system_property_get(const char* key, char* buf),buf[PROP_NAME_MAX]
参数1:获取的属性值,参数2:output:char*

b:设置接口 int __system_property_set(const char *key, const char *value);

参数1:属性值,参数2:value值

原文:http://www.cnblogs.com/snail-micheal/p/4181622.html

评论(0
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!