- 博客(7)
- 资源 (1)
- 问答 (1)
- 收藏
- 关注
原创 如何同时启动多个Tomcat服务
在项目开发中,有时会需要同时启动多个Tomcat服务,如果直接启动多个的话,会报以下错误:Port busy xxxx java.net.SocketException: Unrecognized Windows Sockets error: 0: JVM_Bind,这个就是端口被占用了,所以我们需要做的事就是改端口,首先到tomcat的conf文件夹下找到server.xml配置文件,需要改三个地
2015-08-26 14:09:58 909
原创 java对象转化为JSON格式
package com.gbt.utils;import java.beans.IntrospectionException;import java.beans.Introspector;import java.beans.PropertyDescriptor;import java.util.List;/** * json的操作类 * @author * */public
2015-08-18 11:21:59 1161
原创 JSONObject对象的解析
列子如下:package com.gbt.utils;import java.util.ArrayList;import java.util.List;import com.gbt.model.Accesstoken;import com.gbt.model.ResponseBoxMessage;import com.gbt.model.SubmitResultReturn;import c
2015-08-18 10:04:24 1548
原创 http访问服务器rest格式请求
例子如下:StringBuffer tokenurl = new StringBuffer(); tokenurl.append(Functions.fldUrl()).append("/"); tokenurl.append("token").append("/"); tokenurl.append("get").append("/");
2015-08-18 09:54:16 5869
原创 Utils
读取文件(Properties.xml)中数据import java.io.IOException;import java.io.InputStream;import java.util.Properties;public class PropUtil { static Properties prop = new Properties(); static {
2015-08-18 09:18:16 410
原创 0~9生成随机数4位数
import java.util.Random;public class RandomUtil { /** * 随机获取4位数 * @return */ public String getRandfour(int count) { StringBuffer sb = new StringBuffer(); String str
2015-08-14 12:51:56 5611
原创 使用spring @Scheduled注解执行定时任务
最近看了看spring的 scheduled的使用注解的方式进行调度、感觉很方便、起码配置的东西少了很多、所以留下来以备忘了、============================== 首先 配置Spring-Job.xml文件<?xml version="1.0" encoding="UTF-8"?><beans xmlns="http://www.springframework.org/s
2015-08-07 16:10:36 749
eclipse安装反编译工具jad打开.class文件报错
2015-04-09
TA创建的收藏夹 TA关注的收藏夹
TA关注的人