public class CookiesUtils{ public static void
SetCookie(String key, String value) { SetCookie(key, value, null, null, null,
false); } ...
分类:
其他好文 时间:
2014-07-22 23:16:34
阅读次数:
339
1.获取CSV数据内容public static Object[][]
getFromCSV(String filename) { if (!(new File(filename)).exists()){ return null;
} Object[][] content; CSVReader r....
分类:
Web程序 时间:
2014-07-22 23:16:34
阅读次数:
467
关于instanceof
,两边类型要有关系,通常左边必有钱类型范围大,右边集成左边的类型。public class BasicTypeTest { public static void
main(String[] args) { Object test = 12; boolean flag =.....
分类:
其他好文 时间:
2014-07-22 23:16:12
阅读次数:
284
一、简介REmoteDIctionaryServer(Redis),redis是一个基于内存的单机key/value系统,类似memcached,但支持value为多种形式,包括:字符串(string)、链表(list)、集合(set)、有序集合(sortedset)和hashtable二、特点1优...
分类:
其他好文 时间:
2014-07-22 23:14:34
阅读次数:
462
创建一个类Alt+Shift+N,C,输入Demo,回车创建类属性按3次下方向键,回车,输入String
name;,回车创建构造器Alt+Shift+S,O,回车创建getter/setterAlt+Shift+S,R,空格,回车创建toString方法Alt+Shift+S,S,回车创建main...
分类:
系统相关 时间:
2014-07-22 23:13:57
阅读次数:
503
import java.security.MessageDigest;import
java.util.*;public class Hello2{ public static void main(String[] args) throws
Exception{ Random r = new Ran...
分类:
其他好文 时间:
2014-07-22 23:13:33
阅读次数:
354
Reverse Words in a
String题目链接:http://oj.leetcode.com/problems/reverse-words-in-a-string/ Given an
input string, reverse the string word by word. F...
分类:
其他好文 时间:
2014-07-22 23:13:32
阅读次数:
309
public class DoTXT { // 定义成员变量:路径,文件对象,临时变量
private String path; // 文件路径 private File f; private FileReader fr; // 所需文件流对象
private File...
分类:
其他好文 时间:
2014-07-22 23:13:15
阅读次数:
300
public class ToLog { public static void
main(String[] args) throws Exception { //准备日志文件 File f = new File("log.txt");
if(!f.ex...
分类:
其他好文 时间:
2014-07-22 23:12:54
阅读次数:
300
Given a string, find the length of the longest
substring without repeating characters. For example, the longest substring
without repeating letters fo...
分类:
其他好文 时间:
2014-07-22 23:11:32
阅读次数:
388