
java
teacher3010
这个作者很懒,什么都没留下…
展开
-
求10000内的水仙花数
[code="java"]package equals;import java.io.File;import java.io.FileWriter;import java.io.BufferedWriter;import java.io.FileReader;import java.io.BufferedReader;import java.io.IOException...原创 2012-07-12 10:22:27 · 740 阅读 · 0 评论 -
java JVM
1. Generations for Garbage Collection info: Java objects are created in Heap and Heap is divided into three parts, these are called as Young generation, Tenured or Old Generation and Perm Area. ...2013-03-21 16:57:32 · 103 阅读 · 0 评论 -
读取properties配置文件
读取properties配置文件如下:[code="java"]package conf;import java.io.InputStream;import java.util.Properties;public class ReadProp { public static void main(String[] args){ String fileName =...原创 2012-08-04 22:54:58 · 102 阅读 · 0 评论 -
(转载)如何获取新插入Oracle数据库Sequence值的5种方法
[url]http://blog.youkuaiyun.com/linwei_1029/article/details/7010539[/url]原创 2012-08-16 16:50:52 · 108 阅读 · 0 评论 -
common toString using reflection
core class: package com.itreply.oschina;import java.lang.reflect.Field;public class GeneralToString { public static String toString(Object obj) { if(obj == null) return "null";...原创 2013-05-22 13:58:38 · 157 阅读 · 0 评论 -
5 point
1. collection: map/hashmap2. string(like reverse string, stringBuffer...)3. multi-thread4.valatile原创 2013-02-25 16:29:20 · 127 阅读 · 0 评论 -
1: string VS stringBuffer VS StringBuilder
[b]1)[/b] String is immutable while StringBuffer and StringBuilder is mutable object.[b]2)[/b] StringBuffer is synchronized while StringBuilder is not which makes StringBuilder faster than StringBuf...原创 2013-02-27 11:24:16 · 103 阅读 · 0 评论 -
transient
[b]What are transient variables? What role do they play in Serialization process?[/b]The transient keyword in Java is used to indicate that a field should not be serialized. Once the process of de-s...原创 2013-02-27 18:29:11 · 156 阅读 · 0 评论