- 浏览: 25073 次
- 性别:
- 来自: 北京
最新评论
-
奎河少年:
MauerSu 写道httpClient是哪个 版本的啊 4. ...
HttpTool工具类 -
MauerSu:
httpClient是哪个 版本的啊
HttpTool工具类
文章列表
查看系统端口:netstat –naop |grep 8080
查看tomcat端口被占用:lsof -i:8081
import java.util.Scanner;
public class Test {
public static void main(String[] args) {
int englishCount = 0;// 英文字母个数
int spaceCount = 0;// 空格个数
int numCount = 0;// 数字个数
int otherCount = 0;// 其他字符个数
Scanner sc = new Scanner(System.i ...
lsattr /etc/passwd
chattr -i /etc/passwd
看这个文件的属性,如果中间有一个i。就用chattr -i 去掉
import java.io.BufferedReader;import java.io.IOException;import java.io.InputStreamReader;public class MyEclipseGen { private static final String LL = "Decompiling this copyrighted software is a violation of both your license agreement and the Digital Millenium Copyright Act of 1998 (http://w ...
如何测试服务器上部署历史上线版本?
受用范围:所有接入usp的web站点
操作方法:
[root@localhost online] # cd /opt/script/jwdf_infolist/jwdf_infolist/online
[root@localhost online]# svn update [root@localhost online]# svn log online.tar.gz |more [root@localhost online]# svn update -r 3173 online.tar.gz
[root@localhost on ...
linux文件打包tar.gz命令汇总
- 博客分类:
- linux
linux文件打包tar.gz的命令
FileName:打包后的文件名
DirName:需要打包的文件名
01-.tar格式解包:[*******]$ tar xvf FileName.tar打包:[*******]$ tar cvf FileName.tar DirName(注:tar是打包,不是压缩!)02-.gz ...
BaseXMLData
- 博客分类:
- java基础
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;
import java.util.ArrayList;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationE ...
BaseINIData
- 博客分类:
- java基础
import java.io.BufferedReader;
import java.io.FileReader;
import java.util.ArrayList;
import java.util.List;
import ch.ubique.inieditor.IniEditor;
public class BaseINIData implements IData {
private String defaultPath = "data/";
private String split = ",";
priva ...
public interface IData {
public Object[][] getData(String caseName, String dataFile);
public Object[][] getData(String caseName, String dataFile,int colNum) ;
}
import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class TestReg {
public static void main(String[] args) {
Pattern p = Pattern.compile("java",Pattern.CASE_INSENSITIVE);//忽略大小写
String s = "java Java JaVa JAVA ILoveJava youHatejava sohu.com&quo ...
import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class Test {
public static void main(String[] args) {
//简单认识正则表达式的概念
/*
p("abc".matches("..."));
p("a8729a".replaceAll("\\d", "-"));
Pattern p = Pattern.c ...
抓去email地址程序
- 博客分类:
- java基础
import java.io.BufferedReader;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class EmailSpider {
public static void main(String[] args) {
try {
BufferedReader br ...
import java.io.BufferedReader;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
public class CodeCounter {
static long normalLines = 0;
static long commentLines = 0;
static long whiteLines = 0;
public static void m ...
HttpTool工具类
- 博客分类:
- java基础
package tool;
import java.io.File;
import java.nio.charset.Charset;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import org.apache.http.HttpHost;
import org.apache.http.HttpResponse;
import org.apache.http.NameValuePair;
import org.apache.http.client.HttpClient ...
myDataProvider
- 博客分类:
- java基础
package data;
import java.lang.reflect.Method;
import java.util.HashMap;
import java.util.Map;
import org.testng.AssertJUnit;
import org.testng.annotations.DataProvider;
import com.bj58.qa.atf.data.BaseINIData;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSON ...