본문 바로가기

Java

(36)
Java 애플리케이션 프로파일링 HPROF: A Heap/CPU Profiling Tool in J2SE 5.0 http://java.sun.com/developer/technicalArticles/Programming/HPROF.html Diagnose common runtime problems with hprof http://www.javaworld.com/javaworld/jw-12-2001/jw-1207-hprof.html GUI 환경이 제공되지 않아 명령줄에서 프로파일링해야할 때 참고할만 기사. Java Application Profiling using TPTP http://www.eclipse.org/articles/Article-TPTP-Profiling-Tool/tptpProfilingArticle.html 이클립스 플러..
Java Core Dump File Analysis - IBM Java Core Analyzer Related posts in this website for your search Troubleshooting Java on Solaris Java: Open Source RIA using Apache Pivot Eclipse Memory Analyzer Open Source ASP.NET Blogging Engine Binary Core File Analysis Here are various tools to analyze core dump file under different platforms. Solaris - dbx or gdb Linux - gdb HP-UX - gdb or adb AIX - gdb Windows - Dr. Watson or WinDbg or use pstack or pmap Re..
java - Thread Monitoring with Java SE 5 Thread Monitoring with Java SE 5 Last updated Mar 17, 2006. Java SE 5 defined a host of new monitoring and management interfaces that interact directly with the JVM and exposed them through the java.lang.management package. Included in this package is a managed bean that exposes information about all threads running in the JVM, namely the ThreadMXBean. Each JVM maintains a single instance of the..
Java - HashSetExample import java.util.*; public class HashSetExample { private static String names[] = { "bob", "hemanth", "hhh", "hero", "shawn", "bob", "mike", "Rick", "rock", "hemanth", "mike", "undertaker" }; public static void main(String args[]) { ArrayList aList; aList = new ArrayList(Arrays.asList(names)); System.out.println("The names elements " + aList); HashSet ref = new HashSet(aList); // create a HashSe..
Java - Iterator Example import java.util.Hashtable; import java.util.Iterator; import java.util.Set; import java.util.Map; public class IteratorExample { public static void main(String[] args) { Hashtable hTable=new Hashtable(); hTable.put(new Integer(2), "Two"); hTable.put(new Integer(1), "One"); hTable.put(new Integer(4), "Four"); hTable.put(new Integer(3), "Three"); Set s =hTable.entrySet(); // Using iterator in has..
Java - Enumeration Example import java.util.Enumeration; import java.util.Vector; public class EnumerationExample { public static void main(String[] args) { Vector vc=new Vector(); vc.add("Two"); vc.add("One"); vc.add("Four"); vc.add("Three"); // Get Enumeration to get value Enumeration em=vc.elements(); while(em.hasMoreElements()) { String value = (String)em.nextElement(); System.out.println("value :"+value); } } } Outpu..
Java - Set Example import java.util.Iterator; import java.util.Set; import java.util.TreeSet; public class SetExample { public static void main(String[] args) { // Set example with implement TreeSet Set s=new TreeSet(); s.add("b"); s.add("a"); s.add("d"); s.add("c"); Iterator it=s.iterator(); while(it.hasNext()) { String value=(String)it.next(); System.out.println("Value :"+value); } } } Output Set Value :a Set Va..
Java - List Example import java.util.Iterator; import java.util.List; import java.util.ArrayList; public class ListExample { public static void main(String[] args) { // List Example implement with ArrayList List ls=new ArrayList(); ls.add("one"); ls.add("Three"); ls.add("two"); ls.add("four"); Iterator it=ls.iterator(); while(it.hasNext()) { String value=(String)it.next(); System.out.println("Value :"+value); } } }..