1,让手机和MAC电脑连接同一网络。2,MAC电脑--》系统偏好设置--->网络---》状态--->“Wi-Fi”已连接至“wifi地址”,其 IP 地址为 192.168.3.17。3,iphone手机--》设置---》无线局域网---》详细信息---》HTTP代理--》手动---》服务器地址设置...
分类:
移动开发 时间:
2014-07-19 21:36:23
阅读次数:
270
/************************************************************** Problem: 2120 User: wangyucheng Language: C++ Result: Time_Limit_Exceed***...
分类:
其他好文 时间:
2014-07-19 19:26:18
阅读次数:
225
Linux应用层想要操作kernel层的API,比如想操作相关GPIO或寄存器,可以通过写一个字符设备驱动来实现。
1、先在rootfs中的 /dev/ 下生成一个字符设备。注意主设备号 和 从设备号。可用如下shell脚本生成:
if [ ! -e audioIN ];then
sudo mknod audioIN c 240 0
fi
生成的设备为 /d...
分类:
系统相关 时间:
2014-07-18 22:36:04
阅读次数:
349
一般情况下如果出现连续跳转的时候,经常会出现result is null的问题,这主要是由于action的type默认类型redirect导致的,
我们只需要在出错的action中指定type=“chain”即可。
例如:
(一般写法:用于同一命名空间的action之间跳转时)
adminMain
(标准写法:用于不同命名空间直接切换跳转...
分类:
编程语言 时间:
2014-07-18 22:19:00
阅读次数:
259
在头文件中包含。
string 到int 的转换
string result=”10000”;
int n=0;
stream<>n;//n等于10000
如果你打算在多次转换中使用同一个stringstream对象,记住再每次转换前要使用clear()方法;
在多次转换中重复使用同一个stringstream(而不是每次都创建一个新的对象)对象最大的好...
分类:
编程语言 时间:
2014-07-18 22:11:03
阅读次数:
354
在通过response导出文件数据的时候,不论是txt还是Excel,如果想让其文件名称为中文,解决方案:response.setCharacterEncoding("UTF-8");response.setContentType("application/txt");//“application/vnd.ms-excel”response.setHeader("Content-disposition","p_w_upload;fi..
分类:
其他好文 时间:
2014-07-17 09:21:52
阅读次数:
221
1)A-->BstartActivity(Context,.class);2)A-->B-->AA:startActivityForResult(intent,0);(此处的0为requestCode)B:a)Intentintent=newIntent();/Intentintent=getIntent();b)intent.putExtra("","");c)setResult(0,intent);(此处的0为resultCode)finish();(销..
分类:
其他好文 时间:
2014-07-17 09:06:31
阅读次数:
247
function get_hs_page(cur_page, total_page) { var result = ""; for(var i = 1; i 1) { i = cur_page - 6; }else if(i == cur_page ...
分类:
Web程序 时间:
2014-07-16 16:44:56
阅读次数:
543
No matter left shift or right shift, the result's sign should always be the same as its left operand.
By default, const numbers in C/C++ is signed.
-Wsign-compare
{
unsigned int j = 3;
...
分类:
其他好文 时间:
2014-07-16 12:59:21
阅读次数:
238
Given a number ‘n’, find the smallest number ‘p’ such that if we multiply all digits of ‘p’, we get ‘n’. The result ‘p’ should have minimum two digits...
分类:
其他好文 时间:
2014-07-16 08:55:04
阅读次数:
208