摘要:
1 # An example log4j configuration file that outputs to System.out. The output information consists of relative time, 2 # log level, thread name, log... 阅读全文
摘要:
在有代理服务器的情况下,需要通过X-FORWARDED-FOR http头来获得真实的用户ip: 1 public final class HTTPUtils { 2 3 private static final String HEADER_X_FORWARDED_FOR = 4 ... 阅读全文
摘要:
1 public static int partition(int[] a, int f, int b) { 2 int pivot = a[f]; 3 while (f = pivot) { 5 b--; 6 ... 阅读全文
摘要:
1 void insertionSort(int[] arr) { 2 int i, j, newValue; 3 for (i = 1; i 0 && arr[j - 1] > newValue) { 7 arr[j] = arr[j - 1]; 8 ... 阅读全文
摘要:
1 import java.net.*; 2 import java.io.*; 3 4 public class Main { 5 public static void main(String[] args) { 6 Socket Skt; 7 String ho... 阅读全文
摘要:
1 public static void main(String a[]){ 2 int i; 3 int array[] = {12,9,4,99,120,1,3,10}; 4 System.out.println("\n\n RoseIndia\n\n"); 5 Sys... 阅读全文
摘要:
1 public void getBMPImage(String source) throws Exception { 2 3 clearNData(); //清除数据保存区 4 FileInputStream ... 阅读全文
摘要:
public void bubbleSort(int[] arr) { boolean swapped = true; int j = 0; int tmp; while (swapped) { swapped = false; j++; for (in... 阅读全文
摘要:
/** * @Descriptionmap 将图片文件转化为字节数组字符串,并对其进行Base64编码处理 * @author temdy * @Date 2015-01-26 * @param path 图片路径 * @return */public static String imageToBa... 阅读全文