最近有一项目要求修改系统时间try{Processprocess=Runtime.getRuntime().exec("su");DataOutputStreamos=newDataOutputStream(process.getOutputStream());os.writeBytes("date-s20150319.024012;\n");os.writeBytes(lastTime);}catch(Exceptione){e.printStackTrace();}
分类:
其他好文 时间:
2015-04-04 01:24:41
阅读次数:
151
将excel文件从jsp页面导入到数据库,先将文件上传到server,然后读取,最后删除掉上传//要加encType="multipart/form-data"批量导入项目0) { com.jspsmart.upload.File file = su.getFiles().getFile(0); ....
分类:
Web程序 时间:
2015-04-03 19:23:40
阅读次数:
169
职责链的模式一、作用多个对象都有机会处理请求,从而避免请求的发送者和接受者之间的耦合关系,将对象连成一条链,并沿着这条链传递该请求,直到有一个对象可以处理它二、类图三、实现(1)定义Handlepublic abstract class Handle { protected Handle su...
分类:
其他好文 时间:
2015-04-02 22:21:48
阅读次数:
147
su:switch userpasswd:ls:list -l:长格式 -h:单位转换 -a:显示所有 -d:显示目录自身属性 -i:index node, inode -r:逆序显示 -R:递归显示pwd:printing working directorycd:change dir...
分类:
系统相关 时间:
2015-04-02 20:31:05
阅读次数:
349
切换用户:su 以管理员身份:sudo显示文件内容:ls -sail mysql*(关键字过滤) 创建文件:touch a1编辑文件:vi a1复制文件:cp source destination重命名(移动):mv A B删除:rm -i A创建目录:mkdir A删除目录:rmdir A(A必须...
分类:
系统相关 时间:
2015-04-01 23:35:14
阅读次数:
222
#import "MyView.h"@interface MyView (){ CGMutablePathRef pathRef;}@end@implementation MyView-(id)initWithCoder:(NSCoder *)aDecoder{ if (self=[su...
分类:
其他好文 时间:
2015-04-01 00:19:54
阅读次数:
114
http://www.odata.org/blog/how-to-use-web-api-odata-to-build-an-odata-v4-service-without-entity-framework/ http://www.asp.net/web-api/overview/odata-su...
分类:
其他好文 时间:
2015-04-01 00:19:50
阅读次数:
275
problem:
Find the contiguous subarray within an array (containing at least one number) which has the largest sum.
For example, given the array [?2,1,?3,4,?1,2,1,?5,4],
the contiguous su...
分类:
其他好文 时间:
2015-03-31 18:00:23
阅读次数:
121
1,启动停止Oracle实例(1) su -oracle(2) echo $ORACLE_SID(3) sqlplus /nolog //以不登录到数据库的方式进入sqlplus环境(4) conn as sysdba // 输入数据库用户名/密码(5) startup //启动 shutdown....
分类:
数据库 时间:
2015-03-31 14:36:19
阅读次数:
169
State machine behaviours are scripts that can be attached to animator states or sub-state machines in an Animator Controller. These can be used to add all sorts of behaviour that is state dependent su...
分类:
编程语言 时间:
2015-03-31 10:58:08
阅读次数:
268