摘要: 1、Java 写入文本文件源码import java.io.BufferedWriter;import java.io.File;import java.io.FileOutputStream;import java.io.IOException;import java.io.OutputStreamWriter; public class TxtWriter { public static void appendToFile(String content, File file) throws IOException { TxtWriter.appendToFile(co... 阅读全文
posted @ 2012-02-29 13:45 月亮的影子 阅读(4635) 评论(0) 推荐(1) 编辑
摘要: View Code 1 import javax.crypto.Cipher; 2 import javax.crypto.spec.IvParameterSpec; 3 import javax.crypto.spec.SecretKeySpec; 4 5 import sun.misc.BASE64Decoder; 6 import sun.misc.BASE64Encoder; 7 8 /******************************************************************************* 9 ... 阅读全文
posted @ 2012-02-29 11:42 月亮的影子 阅读(16769) 评论(1) 推荐(1) 编辑
摘要: import java.security.InvalidAlgorithmParameterException;import java.security.InvalidKeyException;import java.security.NoSuchAlgorithmException;import java.security.SecureRandom;import java.security.spec.AlgorithmParameterSpec;import javax.crypto.BadPaddingException;import javax.crypto.Cipher;import 阅读全文
posted @ 2012-02-29 11:32 月亮的影子 阅读(1903) 评论(0) 推荐(0) 编辑