摘要:
在tomcat配置ssl双向认证的时候,如果修改了keystore的密码并且与key的密码不相同的时候,tomat启动的时候会包错,default context init failed: java.security.unrecoverablekeyexception: cannot recover。如果修改了密码之后一定要保证相同。
......
摘要:
一,准备过程
远程过程调用rpc,基于xml的传输方式,当然低层api,就不用我们操心了,但必须的软件还是要有的,先给个列表清单jdk1.4.2 不用说了xerces解析器 到http://xml.apache.org/上去下载吧,xml-rpc开发包, http://ws.apache.org/xmlrpc/上可以下得到
将以上所有的jar包放到开发环境的classpath中。
二,he......
J2ME HTTP POST
1.通过post方法,发送数据至http server
...... 【程序编程相关:
"Wave dash"】2.大家通常忽略content-type与content-length 【推荐阅读:
[原创]用jar命令将Web应用打包成w】
conn.setrequestproperty("user-agent","profile/midp-1.0 configuration/cldc-1.0" ); 【扩展信息:可以自动跳转到出错页面的servlet/】
conn.setrequestmethod(httpconnection.post); conn.setrequestproperty("content-language", "en-us" );
postmsg = request.getbytes();
conn.setrequestproperty("content-type", "application/x-www-form-urlencoded");
conn.setrequestproperty("content-length",integer.tostring( postmsg != null?postmsg.length : 0 ) );
out = conn.openoutputstream();
out.write(postmsg); ......
摘要:
......datainputstream istrm = conn.opendatainputstream();byte imagedata[];
//如果已知图片尺寸 if (length != -1) { imagedata = new byte[length];
// 读取图片数据至imagedata数组 istrm.readfully(imagedata);
// 图片尺寸未知......