![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
JavaSE
Josh
这个作者很懒,什么都没留下…
展开
-
使用ASM工具动态修改类
下面这个是用 ASM 工具为 Student 类添加一个 public String 类型的 address 属性:1,需要添加属性的原始类:Student.javaJava codepublic class Student { private int age; private String name;转载 2010-04-21 15:27:00 · 3362 阅读 · 2 评论 -
Java删除文件和目录代码
package book.io; import java.io.File; /** * * @author ly * 2011-01-25 * 删除文件或目录 */ public class DeleteFileUtil { /** * 删除文件,可以是单个文件或文件夹 * @param fileName转载 2011-11-25 13:14:06 · 673 阅读 · 0 评论 -
精确的加减乘除运算
import java.math.BigDecimal;public class Arith { // 默认除法运算精度 private static final int DEF_DIV_SCALE = 10; // 这个类不能实例化 private Arith() { } /** * 提供精确的加法运算。 * * @param v1 *转载 2011-11-17 14:38:06 · 547 阅读 · 0 评论 -
java 正则表达式
正则表达式语法 正则表达式是一种文本模式,包括普通字符(例如,a 到 z 之间的字母)和特殊字符(称为“元字符”)。模式描述在搜索文本时要匹配的一个或多个字符串。正则表达式示例 表达式 匹配 /^\s*$/ 匹配空行。 /\d{2}-\d{5}/ 验证由两位数字、一个连字原创 2011-07-07 17:30:48 · 368 阅读 · 0 评论 -
将String转换为ascii码
public static String getAscii(String str) { String tmp; StringBuffer sb = new StringBuffer(1000); char c; int i, j; sb.setLength(0); for (i = 0; i < str.length(); i++) { c = str原创 2011-06-13 15:30:00 · 15380 阅读 · 1 评论 -
Java 6 JVM参数选项大全(中文版)
Java 6 JVM参数选项大全(中文版)<br /> <br />作者:Ken Wu<br />Email: ken.wug@gmail.com<br />转载本文档请注明原文链接 http://kenwublog.com/docs/java6-jvm-options-chinese-edition.htm!<br /> <br />本文是基于最新的SUN官方文档Java SE 6 Hotspot VM Options 编写的译文。主要介绍JVM中的非稳态选项及其使用说明。<br />为了让读者明白每个选原创 2011-04-01 09:50:00 · 563 阅读 · 0 评论 -
Java System Properties
Standard System Properties Property NameDescriptionJava Versionfile.encodingThe character encoding for the default locale1.1file.encoding.pkgThe package that contains the converters that handle converting between local encodings and Unicode1.1file.separat原创 2011-01-29 11:13:00 · 414 阅读 · 0 评论 -
myeclipse 6.5 注册码
myeclipse 6.5 注册码6.5的注册码: (正在使用)id:ads key:nLR8ZC-855550-6651645066927093Subscriber: www.1cn.bizSubscription Code: jLR8ZC-655444-65526656052107345 (已经不能使用了)Subscriber:QQ24785490 Subscription Code:DLR8ZC-855551-65657857678050018原创 2010-09-30 11:29:00 · 690 阅读 · 0 评论 -
使用FtpClient连接FTP服务器
package com.hejx.ftp;import java.io.DataInputStream;import java.io.FileOutputStream;import java.io.IOException;import java.io.FileInputStream;import java.util.ArrayList;import java.util.List;import sun.net.*;import sun.net.ftp.FtpClient;p转载 2010-06-22 11:01:00 · 2234 阅读 · 0 评论 -
java版端口扫描器
package com.hejx.ftp;import java.net.*;public class Scanner implements Runnable { private InetAddress IPAddress; private int Port; private Thread allportThread; public Scanner(String IPAddress, int port) { try { this.IPAddress = this.IPA原创 2010-06-23 11:03:00 · 1742 阅读 · 0 评论 -
java目录拷贝
public static void fileCopy(String src, String dest) { File file = new File(src); if (!file.exists()) { System.out.println(src + " Not Exists. "); return; } File fileb = new File(dest)原创 2011-11-09 15:17:54 · 823 阅读 · 0 评论