You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(73) |
Sep
(92) |
Oct
(9) |
Nov
(80) |
Dec
(60) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(92) |
Feb
(52) |
Mar
(71) |
Apr
(64) |
May
(53) |
Jun
(10) |
Jul
(111) |
Aug
(93) |
Sep
(134) |
Oct
|
Nov
|
Dec
|
From: Lukas P. <pe...@us...> - 2002-03-04 22:22:17
|
Update of /cvsroot/javaprofiler/test/snapshot In directory usw-pr-cvs1:/tmp/cvs-serv32275 Added Files: CutTotals.sed Log Message: helper script for DebugOutput.java --- NEW FILE: CutTotals.sed --- #!/bin/sed -f # This script extracts the "Totals" Part of file generated from DebugOutput. # preskakuj, dokud neni TOTALS 1,/^TOTALS:/d # prekakuj od SAMPLING do konce /^SAMPLING:/,$d # odstranit \r s/ $// # odstranit prazdne radky /^$/d # prefix s/^/TOTALS=/ |
From: Pavel V. <va...@us...> - 2002-03-04 00:14:11
|
Update of /cvsroot/javaprofiler/test/snapshot In directory usw-pr-cvs1:/tmp/cvs-serv10945 Modified Files: TestSnap.java PrintSnap.java Log Message: configuration class added Index: TestSnap.java =================================================================== RCS file: /cvsroot/javaprofiler/test/snapshot/TestSnap.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** TestSnap.java 26 Jan 2002 19:37:37 -0000 1.2 --- TestSnap.java 4 Mar 2002 00:14:09 -0000 1.3 *************** *** 42,45 **** --- 42,46 ---- import net.sourceforge.javaprofiler.jpi.*; + public class TestSnap { *************** *** 52,77 **** public void getSnapShot( ) { ! //conf ! boolean withCPU = true; ! boolean withAlloc = true; ! boolean withMon = true; ! boolean withArenas = true; ! boolean withGC = true; ! boolean withTraces = true; ! boolean withThreads = true; //only traces with more hits than this will be extracted ! int CPUTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; //only traces with more allocations than this will be extracted ! int AllocTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; //only traces with more hits than this will be extracted ! int MonTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; long start = System.currentTimeMillis(); ! Snapshot mirror = new SnapshotImpl( iprof, withCPU, withAlloc, ! withMon, withArenas, withGC, withTraces, withThreads, ! CPUTraces_MinVal, ! AllocTraces_MinVal, ! MonTraces_MinVal); System.out.println( mirror.time() ); --- 53,76 ---- public void getSnapShot( ) { ! ! SnapshotImpl.Configuration conf = new SnapshotImpl.Configuration(); ! ! conf.withCPU = true; ! conf.withAlloc = true; ! conf.withMon = true; ! conf.withArenas = true; ! conf.withGC = true; ! conf.withTraces = true; ! conf.withThreads = true; //only traces with more hits than this will be extracted ! conf.CPUTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; //only traces with more allocations than this will be extracted ! conf.AllocTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; //only traces with more hits than this will be extracted ! conf.MonTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; long start = System.currentTimeMillis(); ! Snapshot mirror = new SnapshotImpl( iprof, conf ); System.out.println( mirror.time() ); Index: PrintSnap.java =================================================================== RCS file: /cvsroot/javaprofiler/test/snapshot/PrintSnap.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** PrintSnap.java 3 Mar 2002 00:26:30 -0000 1.3 --- PrintSnap.java 4 Mar 2002 00:14:09 -0000 1.4 *************** *** 54,75 **** public void printSnapShot( ) { //conf ! boolean withCPU = true; ! boolean withAlloc = true; ! boolean withMon = true; ! boolean withTraces = true; ! boolean withThreads = true; ! boolean withArenas = true; ! boolean withGC = true; ! int CPUTraces_MinVal = IProf.NO_OPTIONAL_ARG; ! int AllocTraces_MinVal = IProf.NO_OPTIONAL_ARG; ! int MonTraces_MinVal = IProf.NO_OPTIONAL_ARG; DebugOutput dbgPrn = new DebugOutput(); ! SnapshotImpl mirror = new SnapshotImpl( iprof, withCPU, withAlloc, ! withMon, withTraces, withThreads, withArenas, withGC, ! CPUTraces_MinVal, ! AllocTraces_MinVal, ! MonTraces_MinVal); dbgPrn.print( mirror ); --- 54,76 ---- public void printSnapShot( ) { //conf ! SnapshotImpl.Configuration conf = new SnapshotImpl.Configuration(); ! ! conf.withCPU = true; ! conf.withAlloc = true; ! conf.withMon = true; ! conf.withArenas = true; ! conf.withGC = true; ! conf.withTraces = true; ! conf.withThreads = true; ! //only traces with more hits than this will be extracted ! conf.CPUTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; ! //only traces with more allocations than this will be extracted ! conf.AllocTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; ! //only traces with more hits than this will be extracted ! conf.MonTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; DebugOutput dbgPrn = new DebugOutput(); ! SnapshotImpl mirror = new SnapshotImpl( iprof, conf ); dbgPrn.print( mirror ); |
From: Pavel V. <va...@us...> - 2002-03-04 00:14:00
|
Update of /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data In directory usw-pr-cvs1:/tmp/cvs-serv10884 Modified Files: SnapshotImpl.java Log Message: configuration class added Index: SnapshotImpl.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/SnapshotImpl.java,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -r1.12 -r1.13 *** SnapshotImpl.java 3 Mar 2002 01:20:09 -0000 1.12 --- SnapshotImpl.java 4 Mar 2002 00:13:56 -0000 1.13 *************** *** 23,26 **** --- 23,27 ---- import java.util.*; + import java.io.Serializable; import net.sourceforge.javaprofiler.jpi.*; *************** *** 36,69 **** * @author Pavel Vacha */ ! public class SnapshotImpl implements Snapshot { private String name; private long time; ! private HashMap libIDs = new HashMap(); //converts libIds to references ! private LinkedList classes = new LinkedList(); ! private LinkedList methods = new LinkedList(); ! private LinkedList groupThreads = new LinkedList(); ! private LinkedList threads = new LinkedList(); ! private LinkedList allocTypes = new LinkedList(); ! private LinkedList arenas = new LinkedList(); ! private LinkedList gcs = new LinkedList(); ! ! //default conf ! private boolean withCPU = true; ! private boolean withAlloc = true; ! private boolean withMon = true; ! private boolean withTraces = true; ! private boolean withThreads = true; ! private boolean withArenas = true; ! private boolean withGC = true; ! //only traces with more hits than this will be extracted ! private int CPUTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; ! //only traces with more allocations than this will be extracted ! private int AllocTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; ! //only traces with more hits than this will be extracted ! private int MonTraces_MinVal = IProf.NO_OPTIONAL_ARG; //2; ! ! //other private boolean haveSnapshot = false; --- 37,92 ---- * @author Pavel Vacha */ ! public class SnapshotImpl implements Snapshot, Serializable { private String name; private long time; ! //PENDING //?transient ! private Map libIDs = new HashMap(); //converts libIds to references ! private List classes = new LinkedList(); ! private List methods = new LinkedList(); ! private List groupThreads = new LinkedList(); ! private List threads = new LinkedList(); ! private List allocTypes = new LinkedList(); ! private List arenas = new LinkedList(); ! private List gcs = new LinkedList(); ! ! private Configuration conf; ! ! /** Configuration object, you can tune you snaphot content. */ ! public static class Configuration implements Cloneable, Serializable { ! /** Whether include snapshot of CPU. */ ! public boolean withCPU = true; ! /** Whether include snapshot of allocations.*/ ! public boolean withAlloc = true; ! /** Whether include snapshot of monitors. */ ! public boolean withMon = true; ! /** Whether include even discrimination to traces. */ ! public boolean withTraces = true; ! /** Whether include discrimination to threads. */ ! public boolean withThreads = true; ! /** Whether inlucde snapshot of arenas. */ ! public boolean withArenas = true; ! /** Whether inlucde snapshot of garbage collector. */ ! public boolean withGC = true; ! /** Whether inlucde call tree */ ! public boolean withCallTree = true; ! /**Only traces with more hits than this will be extracted. ! Use <code>IProf.NO_OPTIONAL_ARG</code> for extraction of all traces.*/ ! public int CPUTraces_MinVal = IProf.NO_OPTIONAL_ARG; ! /**Only traces with more allocations than this will be extracted. ! Use <code>IProf.NO_OPTIONAL_ARG</code> for extraction of all traces.*/ ! public int AllocTraces_MinVal = IProf.NO_OPTIONAL_ARG; ! /**Only traces with more hits than this will be extracted. ! Use <code>IProf.NO_OPTIONAL_ARG</code> for extraction of all traces.*/ ! public int MonTraces_MinVal = IProf.NO_OPTIONAL_ARG; ! ! public Object clone() throws CloneNotSupportedException { ! return super.clone(); ! } ! ! } ! ! //other private boolean haveSnapshot = false; *************** *** 77,80 **** --- 100,104 ---- */ public SnapshotImpl( IProf iprof ) { + this.conf = new Configuration(); //default makeSnapshot( iprof ); } *************** *** 84,124 **** * *@param iprof Communacation object (you have to be connected to profiled VM). ! *@param withCPU Whether include snapshot of CPU. ! *@param withAlloc Whether include snapshot of allocations. ! *@param withMon Whether include snapshot of monitors. ! *@param withArenas Whether inlucde snapshot of arenas. ! *@param withGC Whether inlucde snapshot of garbage collector. ! * ! *@param withTraces Whether include even discrimination to traces. ! *@param withThreads Whether include discrimination to threads. ! * ! *@param CPUTraces_MinVal Only traces with more hits than this will be extracted. ! * Use <code>IProf.NO_OPTIONAL_ARG</code> for extraction of all traces. ! *@param AllocTraces_MinVal Only traces with more allocations than this will be extracted. ! * Use <code>IProf.NO_OPTIONAL_ARG</code> for extraction of all traces. ! *@param MonTraces_MinVal Only traces with more hits than this will be extracted. ! * Use <code>IProf.NO_OPTIONAL_ARG</code> for extraction of all traces. */ //maybe use some configuration object ! public SnapshotImpl( IProf iprof, boolean withCPU, boolean withAlloc, ! boolean withMon, boolean withTraces, ! boolean withThreads, boolean withArenas, boolean withGC, ! int CPUTraces_MinVal, ! int AllocTraces_MinVal, ! int MonTraces_MinVal ) { ! this.withCPU = withCPU; ! this.withAlloc = withAlloc; ! this.withMon = withMon; ! this.withTraces = withTraces; ! this.withThreads = withThreads; ! this.withGC = withGC; ! this.withArenas = withArenas; ! this.CPUTraces_MinVal = CPUTraces_MinVal; ! this.AllocTraces_MinVal = AllocTraces_MinVal; ! this.MonTraces_MinVal = MonTraces_MinVal; ! makeSnapshot( iprof ); } ! ////////////////////////////////////////////////////////////////////////// // implementation of Snapdhot interface --- 108,125 ---- * *@param iprof Communacation object (you have to be connected to profiled VM). ! *@param conf Configuration object, you can tune you snaphot content */ //maybe use some configuration object ! public SnapshotImpl( IProf iprof, Configuration conf ) { ! //PENDING ! try { ! this.conf = (Configuration) conf.clone(); ! makeSnapshot( iprof ); ! } catch( Exception e) { ! System.err.println( e ); ! } } ! ////////////////////////////////////////////////////////////////////////// // implementation of Snapdhot interface *************** *** 330,336 **** long start = System.currentTimeMillis(); ! LinkedList actLst = new LinkedList(); //temporary list ! LinkedList actLst2 = new LinkedList(); //temporary list ! LinkedList actLst3 = new LinkedList(); try { --- 331,337 ---- long start = System.currentTimeMillis(); ! List actLst = new LinkedList(); //temporary list ! List actLst2 = new LinkedList(); //temporary list ! List actLst3 = new LinkedList(); try { *************** *** 338,342 **** ! if (withCPU || withAlloc || withMon) { extract( null, classes, IProf.CLASSES, IProf.NO_OPTIONAL_ARG, iprof ); //get class fields --- 339,343 ---- ! if (conf.withCPU || conf.withAlloc || conf.withMon) { extract( null, classes, IProf.CLASSES, IProf.NO_OPTIONAL_ARG, iprof ); //get class fields *************** *** 345,349 **** //extract( classes, methods, IProf.CLASS_METHODS, IProf.NO_OPTIONAL_ARG, iprof ); extract( null, methods, IProf.METHODS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( withThreads ) { extract( null, groupThreads, IProf.GROUPS_OF_THREADS, IProf.NO_OPTIONAL_ARG, iprof ); --- 346,350 ---- //extract( classes, methods, IProf.CLASS_METHODS, IProf.NO_OPTIONAL_ARG, iprof ); extract( null, methods, IProf.METHODS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( conf.withThreads ) { extract( null, groupThreads, IProf.GROUPS_OF_THREADS, IProf.NO_OPTIONAL_ARG, iprof ); *************** *** 354,375 **** } } ! if( withCPU ) { ! if( withTraces ) { //extract( methods, null, IProf.CPU_METHOD_TRACES, // CPUTraces_MinVal, iprof ); extract( null, null, IProf.CPU_TRACES, ! CPUTraces_MinVal, iprof ); } ! if( withThreads ) { ! extract( threads, (withTraces) ? actLst : null, IProf.CPU_THREAD_METHODS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( withTraces ) { extract( actLst, null, IProf.CPU_THREAD_METHOD_TRACES, ! CPUTraces_MinVal, iprof ); } } } ! if( withAlloc ) { actLst3.clear(); actLst2.clear(); --- 355,376 ---- } } ! if( conf.withCPU ) { ! if( conf.withTraces ) { //extract( methods, null, IProf.CPU_METHOD_TRACES, // CPUTraces_MinVal, iprof ); extract( null, null, IProf.CPU_TRACES, ! conf.CPUTraces_MinVal, iprof ); } ! if( conf.withThreads ) { ! extract( threads, (conf.withTraces) ? actLst : null, IProf.CPU_THREAD_METHODS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( conf.withTraces ) { extract( actLst, null, IProf.CPU_THREAD_METHOD_TRACES, ! conf.CPUTraces_MinVal, iprof ); } } } ! if( conf.withAlloc ) { actLst3.clear(); actLst2.clear(); *************** *** 377,392 **** extract( null, allocTypes, IProf.OBJECT_TYPES, IProf.NO_OPTIONAL_ARG, iprof ); ! extract( allocTypes, (withTraces)? actLst : null, IProf.ALLOC_OBJECT_METHODS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( withTraces ) { //extract( methods, null, IProf.ALLOC_METHOD_TRACES, // AllocTraces_MinVal, iprof ); extract( null, null, IProf.ALLOC_TRACES, ! AllocTraces_MinVal, iprof ); extract( actLst, null, IProf.ALLOC_OBJECT_METHOD_TRACES, ! AllocTraces_MinVal, iprof ); } ! if( withThreads ) { actLst.clear(); actLst2.clear(); --- 378,393 ---- extract( null, allocTypes, IProf.OBJECT_TYPES, IProf.NO_OPTIONAL_ARG, iprof ); ! extract( allocTypes, (conf.withTraces)? actLst : null, IProf.ALLOC_OBJECT_METHODS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( conf.withTraces ) { //extract( methods, null, IProf.ALLOC_METHOD_TRACES, // AllocTraces_MinVal, iprof ); extract( null, null, IProf.ALLOC_TRACES, ! conf.AllocTraces_MinVal, iprof ); extract( actLst, null, IProf.ALLOC_OBJECT_METHOD_TRACES, ! conf.AllocTraces_MinVal, iprof ); } ! if( conf.withThreads ) { actLst.clear(); actLst2.clear(); *************** *** 396,414 **** extract( threads, actLst, IProf.ALLOC_THREAD_METHODS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( withTraces ) { extract( actLst, null, IProf.ALLOC_THREAD_METHOD_TRACES, ! AllocTraces_MinVal, iprof ); } ! extract( actLst, (withTraces)? actLst2 : null, IProf.ALLOC_THREAD_METHOD_OBJECTS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( withTraces ) { extract( actLst2, null, IProf.ALLOC_THREAD_OBJECT_METHOD_TRACES, ! AllocTraces_MinVal, iprof); } } } ! if( withMon ) { ! if( withTraces ) { //extract( methods, null, IProf.MON_METHOD_TRACES, // IProf.NO_OPTIONAL_ARG, iprof ); --- 397,415 ---- extract( threads, actLst, IProf.ALLOC_THREAD_METHODS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( conf.withTraces ) { extract( actLst, null, IProf.ALLOC_THREAD_METHOD_TRACES, ! conf.AllocTraces_MinVal, iprof ); } ! extract( actLst, (conf.withTraces)? actLst2 : null, IProf.ALLOC_THREAD_METHOD_OBJECTS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( conf.withTraces ) { extract( actLst2, null, IProf.ALLOC_THREAD_OBJECT_METHOD_TRACES, ! conf.AllocTraces_MinVal, iprof); } } } ! if( conf.withMon ) { ! if( conf.withTraces ) { //extract( methods, null, IProf.MON_METHOD_TRACES, // IProf.NO_OPTIONAL_ARG, iprof ); *************** *** 416,435 **** IProf.NO_OPTIONAL_ARG, iprof ); } ! if( withThreads ) { actLst.clear(); ! extract( threads, (withTraces) ? actLst : null, IProf.MON_THREAD_METHODS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( withTraces ) { extract( actLst, null, IProf.MON_THREAD_METHOD_TRACES, ! MonTraces_MinVal, iprof ); } } } ! if ( withArenas ) { extract( null, arenas, IProf.ARENAS, IProf.NO_OPTIONAL_ARG, iprof ); } ! if ( withGC ) { extract( null, gcs, IProf.GCS, IProf.NO_OPTIONAL_ARG, iprof ); } --- 417,436 ---- IProf.NO_OPTIONAL_ARG, iprof ); } ! if( conf.withThreads ) { actLst.clear(); ! extract( threads, (conf.withTraces) ? actLst : null, IProf.MON_THREAD_METHODS, IProf.NO_OPTIONAL_ARG, iprof ); ! if( conf.withTraces ) { extract( actLst, null, IProf.MON_THREAD_METHOD_TRACES, ! conf.MonTraces_MinVal, iprof ); } } } ! if ( conf.withArenas ) { extract( null, arenas, IProf.ARENAS, IProf.NO_OPTIONAL_ARG, iprof ); } ! if ( conf.withGC ) { extract( null, gcs, IProf.GCS, IProf.NO_OPTIONAL_ARG, iprof ); } *************** *** 439,443 **** } catch( Exception e ) { ! System.out.println( "Just error\n" + e); } --- 440,444 ---- } catch( Exception e ) { ! System.out.println( "Just error\n" + e ); } *************** *** 1036,1039 **** --- 1037,1043 ---- /* * $Log$ + * Revision 1.13 2002/03/04 00:13:56 vachis + * configuration class added + * * Revision 1.12 2002/03/03 01:20:09 vachis * type of ID changed from int to Integer |
Update of /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data In directory usw-pr-cvs1:/tmp/cvs-serv16074 Modified Files: AllocAbstractStatThreadTypeData.java AllocArenaData.java AllocStatIDObjectData.java AllocThreadMethodData.java AllocThreadTraceData.java AllocThreadTypeData.java AllocThreadTypeMethodData.java AllocThreadTypeTraceData.java AllocTraceData.java AllocTypeData.java AllocTypeMethodData.java AllocTypeTraceData.java CPUStatIDObjectData.java CPUThreadMethodData.java CPUThreadTraceData.java CPUTraceData.java ClassData.java ClassFieldData.java GCData.java IDObjectData.java MethodData.java MonStatIDObjectData.java MonThreadMethodData.java MonThreadTraceData.java MonTraceData.java SnapshotImpl.java ThreadData.java ThreadGroupData.java Log Message: type of ID changed from int to Integer Index: AllocAbstractStatThreadTypeData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocAbstractStatThreadTypeData.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** AllocAbstractStatThreadTypeData.java 1 Mar 2002 11:48:57 -0000 1.1 --- AllocAbstractStatThreadTypeData.java 3 Mar 2002 01:20:08 -0000 1.2 *************** *** 33,37 **** * @param ID unique ID. */ ! protected AllocAbstractStatThreadTypeData(int ID) { super(ID); } --- 33,37 ---- * @param ID unique ID. */ ! protected AllocAbstractStatThreadTypeData(Integer ID) { super(ID); } *************** *** 41,44 **** --- 41,47 ---- /* * $Log$ + * Revision 1.2 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.1 2002/03/01 11:48:57 vachis * rename of class *************** *** 55,57 **** * no message * ! */ \ No newline at end of file --- 58,60 ---- * no message * ! */ Index: AllocArenaData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocArenaData.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -r1.4 -r1.5 *** AllocArenaData.java 1 Dec 2001 15:58:52 -0000 1.4 --- AllocArenaData.java 3 Mar 2002 01:20:08 -0000 1.5 *************** *** 32,36 **** public class AllocArenaData extends IDObjectData { /** ID of the arena. */ ! private int arenaID; /** Name of the arena. */ private String name; --- 32,36 ---- public class AllocArenaData extends IDObjectData { /** ID of the arena. */ ! private Integer arenaID; /** Name of the arena. */ private String name; *************** *** 51,55 **** * @param active determines whether the arena is active. */ ! AllocArenaData(int ID, int arenaID, String name, boolean active) { super(ID); this.arenaID=arenaID; --- 51,55 ---- * @param active determines whether the arena is active. */ ! AllocArenaData(Integer ID, Integer arenaID, String name, boolean active) { super(ID); this.arenaID=arenaID; *************** *** 65,70 **** AllocArenaData( IProf.sID sid ) { // fills fields: active, arenaID, name ! this( sid.objId, sid.objId, ((IProf.sArenaInfo) sid.info).arenaName, ! sid.active ); } --- 65,70 ---- AllocArenaData( IProf.sID sid ) { // fills fields: active, arenaID, name ! this( new Integer(sid.objId), new Integer(sid.objId), ! ((IProf.sArenaInfo) sid.info).arenaName, sid.active ); } *************** *** 74,78 **** * @return ID of the arena. */ ! public int getArenaID() { return arenaID; } --- 74,78 ---- * @return ID of the arena. */ ! public Integer getArenaID() { return arenaID; } *************** *** 128,131 **** --- 128,134 ---- /* * $Log$ + * Revision 1.5 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.4 2001/12/01 15:58:52 petrul * changed constructor code *************** *** 140,142 **** * no message * ! */ \ No newline at end of file --- 143,145 ---- * no message * ! */ Index: AllocStatIDObjectData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocStatIDObjectData.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** AllocStatIDObjectData.java 1 Dec 2001 17:41:31 -0000 1.3 --- AllocStatIDObjectData.java 3 Mar 2002 01:20:08 -0000 1.4 *************** *** 43,47 **** * @param ID unique ID. */ ! protected AllocStatIDObjectData(int ID) { super(ID); } --- 43,47 ---- * @param ID unique ID. */ ! protected AllocStatIDObjectData(Integer ID) { super(ID); } *************** *** 121,124 **** --- 121,127 ---- /* * $Log$ + * Revision 1.4 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.3 2001/12/01 17:41:31 petrul * added private fields setting method *************** *** 135,137 **** * no message * ! */ \ No newline at end of file --- 138,140 ---- * no message * ! */ Index: AllocThreadMethodData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocThreadMethodData.java,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -r1.11 -r1.12 *** AllocThreadMethodData.java 1 Mar 2002 11:40:12 -0000 1.11 --- AllocThreadMethodData.java 3 Mar 2002 01:20:08 -0000 1.12 *************** *** 53,57 **** * @param method allocation data for this method. */ ! AllocThreadMethodData(int ID, ThreadData thread, MethodData method) { super(ID); this.thread=thread; --- 53,57 ---- * @param method allocation data for this method. */ ! AllocThreadMethodData(Integer ID, ThreadData thread, MethodData method) { super(ID); this.thread=thread; *************** *** 69,73 **** */ AllocThreadMethodData( IProf.sID sid, ThreadData thread, MethodData method ) { ! this( sid.objId, thread, method ); //if (sid.alloc!=null) //do not test this, its an error --- 69,73 ---- */ AllocThreadMethodData( IProf.sID sid, ThreadData thread, MethodData method ) { ! this( new Integer( sid.objId ), thread, method ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 111,115 **** void addType(AllocThreadTypeMethodData allocType) { //FIXME ! types.put(new Integer(allocType.getID()), allocType); } --- 111,115 ---- void addType(AllocThreadTypeMethodData allocType) { //FIXME ! types.put( allocType.getID(), allocType); } *************** *** 123,128 **** * not exist. */ ! public AllocThreadTypeMethodData getType(int ID) { ! return (AllocThreadTypeMethodData)types.get(new Integer(ID)); } --- 123,128 ---- * not exist. */ ! public AllocThreadTypeMethodData getType(Integer ID) { ! return (AllocThreadTypeMethodData)types.get( ID ); } *************** *** 142,146 **** */ void addTrace(AllocThreadTraceData trace) { ! traces.put(new Integer(trace.getTrace().getID()), trace); } --- 142,146 ---- */ void addTrace(AllocThreadTraceData trace) { ! traces.put( trace.getTrace().getID(), trace); } *************** *** 152,157 **** * <code>null</code> if such trace does not exist. */ ! public AllocThreadTraceData getTrace(int ID) { ! return (AllocThreadTraceData)traces.get(new Integer(ID)); } --- 152,157 ---- * <code>null</code> if such trace does not exist. */ ! public AllocThreadTraceData getTrace(Integer ID) { ! return (AllocThreadTraceData)traces.get( ID ); } *************** *** 160,163 **** --- 160,166 ---- /* * $Log$ + * Revision 1.12 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.11 2002/03/01 11:40:12 vachis * doc changes Index: AllocThreadTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocThreadTraceData.java,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -r1.11 -r1.12 *** AllocThreadTraceData.java 1 Mar 2002 11:40:12 -0000 1.11 --- AllocThreadTraceData.java 3 Mar 2002 01:20:08 -0000 1.12 *************** *** 48,52 **** * @param threadMethod allocation data for this thread and method. */ ! AllocThreadTraceData(int ID, AllocThreadMethodData threadMethod, AllocTraceData trace) { super(ID); --- 48,52 ---- * @param threadMethod allocation data for this thread and method. */ ! AllocThreadTraceData(Integer ID, AllocThreadMethodData threadMethod, AllocTraceData trace) { super(ID); *************** *** 64,68 **** AllocThreadTraceData( IProf.sID sid, AllocThreadMethodData threadMethod, AllocTraceData trace ) { ! this( sid.objId, threadMethod, trace ); //if (sid.alloc!=null) //do not test this, its an error --- 64,68 ---- AllocThreadTraceData( IProf.sID sid, AllocThreadMethodData threadMethod, AllocTraceData trace ) { ! this( new Integer(sid.objId), threadMethod, trace ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 107,111 **** void addType(AllocThreadTypeTraceData allocType) { // FIXME: ! types.put(new Integer(allocType.getID()), allocType); } --- 107,111 ---- void addType(AllocThreadTypeTraceData allocType) { // FIXME: ! types.put( allocType.getID(), allocType); } *************** *** 119,124 **** * not exist. */ ! public AllocThreadTypeTraceData getType(int ID) { ! return (AllocThreadTypeTraceData)types.get(new Integer(ID)); } --- 119,124 ---- * not exist. */ ! public AllocThreadTypeTraceData getType(Integer ID) { ! return (AllocThreadTypeTraceData)types.get( ID ); } *************** *** 127,130 **** --- 127,133 ---- /* * $Log$ + * Revision 1.12 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.11 2002/03/01 11:40:12 vachis * doc changes Index: AllocThreadTypeData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocThreadTypeData.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** AllocThreadTypeData.java 1 Mar 2002 11:40:12 -0000 1.2 --- AllocThreadTypeData.java 3 Mar 2002 01:20:08 -0000 1.3 *************** *** 47,51 **** * @param type allocation data for this class. */ ! AllocThreadTypeData(int ID, ThreadData thread, AllocTypeData type) { super(ID); this.thread=thread; --- 47,51 ---- * @param type allocation data for this class. */ ! AllocThreadTypeData(Integer ID, ThreadData thread, AllocTypeData type) { super(ID); this.thread=thread; *************** *** 62,66 **** */ AllocThreadTypeData( IProf.sID sid, ThreadData thread, AllocTypeData type ) { ! this( sid.objId, thread, type ); //if (sid.alloc!=null) //do not test this, its an error --- 62,66 ---- */ AllocThreadTypeData( IProf.sID sid, ThreadData thread, AllocTypeData type ) { ! this( new Integer(sid.objId) , thread, type ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 105,109 **** */ void addMethod(AllocThreadTypeMethodData method) { ! methods.put(new Integer(method.getTypeMethod().getMethod().getID()), method); } --- 105,109 ---- */ void addMethod(AllocThreadTypeMethodData method) { ! methods.put( method.getTypeMethod().getMethod().getID(), method); } *************** *** 117,122 **** * not exist. */ ! public AllocThreadTypeMethodData getMethod(int ID) { ! return (AllocThreadTypeMethodData)methods.get(new Integer(ID)); } --- 117,122 ---- * not exist. */ ! public AllocThreadTypeMethodData getMethod(Integer ID) { ! return (AllocThreadTypeMethodData)methods.get( ID ); } *************** *** 125,128 **** --- 125,131 ---- /* * $Log$ + * Revision 1.3 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.2 2002/03/01 11:40:12 vachis * doc changes Index: AllocThreadTypeMethodData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocThreadTypeMethodData.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** AllocThreadTypeMethodData.java 1 Mar 2002 11:40:12 -0000 1.2 --- AllocThreadTypeMethodData.java 3 Mar 2002 01:20:08 -0000 1.3 *************** *** 52,56 **** * @param threadMethod allocation data for this thread and method. */ ! AllocThreadTypeMethodData(int ID, AllocThreadTypeData threadType, AllocTypeMethodData typeMethod, AllocThreadMethodData threadMethod) { super(ID); --- 52,56 ---- * @param threadMethod allocation data for this thread and method. */ ! AllocThreadTypeMethodData(Integer ID, AllocThreadTypeData threadType, AllocTypeMethodData typeMethod, AllocThreadMethodData threadMethod) { super(ID); *************** *** 72,76 **** AllocThreadTypeMethodData( IProf.sID sid, AllocThreadTypeData threadType, AllocTypeMethodData typeMethod, AllocThreadMethodData threadMethod ) { ! this( sid.objId, threadType, typeMethod, threadMethod ); //if (sid.alloc!=null) //do not test this, its an error --- 72,76 ---- AllocThreadTypeMethodData( IProf.sID sid, AllocThreadTypeData threadType, AllocTypeMethodData typeMethod, AllocThreadMethodData threadMethod ) { ! this( new Integer(sid.objId), threadType, typeMethod, threadMethod ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 123,127 **** */ void addTrace(AllocThreadTypeTraceData trace) { ! traces.put(new Integer(trace.getTypeTrace().getTrace().getID()), trace); } --- 123,127 ---- */ void addTrace(AllocThreadTypeTraceData trace) { ! traces.put(trace.getTypeTrace().getTrace().getID(), trace); } *************** *** 135,140 **** * trace does not exist. */ ! public AllocThreadTypeTraceData getTrace(int ID) { ! return (AllocThreadTypeTraceData)traces.get(new Integer(ID)); } --- 135,140 ---- * trace does not exist. */ ! public AllocThreadTypeTraceData getTrace(Integer ID) { ! return (AllocThreadTypeTraceData)traces.get( ID ); } *************** *** 143,146 **** --- 143,149 ---- /* * $Log$ + * Revision 1.3 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.2 2002/03/01 11:40:12 vachis * doc changes Index: AllocThreadTypeTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocThreadTypeTraceData.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** AllocThreadTypeTraceData.java 1 Mar 2002 11:40:12 -0000 1.2 --- AllocThreadTypeTraceData.java 3 Mar 2002 01:20:08 -0000 1.3 *************** *** 43,47 **** * @param threadTrace allocation data for this thread and trace. */ ! AllocThreadTypeTraceData(int ID, AllocTypeTraceData typeTrace, AllocThreadTypeMethodData threadTypeMethod, AllocThreadTraceData threadTrace) { --- 43,47 ---- * @param threadTrace allocation data for this thread and trace. */ ! AllocThreadTypeTraceData(Integer ID, AllocTypeTraceData typeTrace, AllocThreadTypeMethodData threadTypeMethod, AllocThreadTraceData threadTrace) { *************** *** 63,67 **** AllocThreadTypeMethodData threadClassMethod, AllocThreadTraceData threadTrace ) { ! this( sid.objId, classTrace, threadClassMethod, threadTrace ); //if (sid.alloc!=null) //do not test this, its an error --- 63,67 ---- AllocThreadTypeMethodData threadClassMethod, AllocThreadTraceData threadTrace ) { ! this( new Integer(sid.objId), classTrace, threadClassMethod, threadTrace ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 100,103 **** --- 100,106 ---- /* * $Log$ + * Revision 1.3 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.2 2002/03/01 11:40:12 vachis * doc changes Index: AllocTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocTraceData.java,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -r1.13 -r1.14 *** AllocTraceData.java 1 Mar 2002 11:40:12 -0000 1.13 --- AllocTraceData.java 3 Mar 2002 01:20:08 -0000 1.14 *************** *** 57,61 **** * <code>List</code> of {@link TraceFrameData} objects. */ ! AllocTraceData(int ID, MethodData method, List frames) { super(ID); this.method=method; --- 57,61 ---- * <code>List</code> of {@link TraceFrameData} objects. */ ! AllocTraceData(Integer ID, MethodData method, List frames) { super(ID); this.method=method; *************** *** 73,77 **** */ AllocTraceData( IProf.sID sid, MethodData method, List frames ) { ! this( sid.objId, method, frames ); //if (sid.alloc!=null) //do not test this, its an error --- 73,77 ---- */ AllocTraceData( IProf.sID sid, MethodData method, List frames ) { ! this( new Integer(sid.objId), method, frames ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 114,118 **** void addType(AllocTypeTraceData allocType) { //FIXMEE: ! types.put(new Integer(allocType.getID()), allocType); } --- 114,118 ---- void addType(AllocTypeTraceData allocType) { //FIXMEE: ! types.put(allocType.getID(), allocType); } *************** *** 125,130 **** * in this trace or <code>null</code> if such type does not exist. */ ! public AllocTypeTraceData getType(int ID) { ! return (AllocTypeTraceData)types.get(new Integer(ID)); } --- 125,130 ---- * in this trace or <code>null</code> if such type does not exist. */ ! public AllocTypeTraceData getType(Integer ID) { ! return (AllocTypeTraceData)types.get( ID ); } *************** *** 144,148 **** */ void addThread(AllocThreadTraceData thread) { ! threads.put( new Integer(thread.getThreadMethod().getThread().getID()), thread); } --- 144,148 ---- */ void addThread(AllocThreadTraceData thread) { ! threads.put( thread.getThreadMethod().getThread().getID(), thread); } *************** *** 154,159 **** * or <code>null</code> if such thread does not exist. */ ! public AllocThreadTraceData getThread(int ID) { ! return (AllocThreadTraceData)threads.get(new Integer(ID)); } --- 154,159 ---- * or <code>null</code> if such thread does not exist. */ ! public AllocThreadTraceData getThread(Integer ID) { ! return (AllocThreadTraceData)threads.get(ID); } *************** *** 163,166 **** --- 163,169 ---- /* * $Log$ + * Revision 1.14 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.13 2002/03/01 11:40:12 vachis * doc changes Index: AllocTypeData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocTypeData.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -r1.4 -r1.5 *** AllocTypeData.java 1 Mar 2002 11:40:12 -0000 1.4 --- AllocTypeData.java 3 Mar 2002 01:20:08 -0000 1.5 *************** *** 56,60 **** * @param arrayType arrayType of this type. */ ! AllocTypeData(int ID, ClassData classData, int arrayType) { super(ID); this.clazz=classData; --- 56,60 ---- * @param arrayType arrayType of this type. */ ! AllocTypeData(Integer ID, ClassData classData, int arrayType) { super(ID); this.clazz=classData; *************** *** 70,74 **** */ AllocTypeData(IProf.sID sid, ClassData clazz) { ! this( sid.objId, clazz, ((IProf.sObjectInfo) sid.info).isArray ); //if (sid.alloc != null) //do not test this, its an error --- 70,74 ---- */ AllocTypeData(IProf.sID sid, ClassData clazz) { ! this( new Integer(sid.objId), clazz, ((IProf.sObjectInfo) sid.info).isArray ); //if (sid.alloc != null) //do not test this, its an error *************** *** 109,113 **** */ void addMethod(AllocTypeMethodData method) { ! methods.put(new Integer(method.getMethod().getID()), method); } --- 109,113 ---- */ void addMethod(AllocTypeMethodData method) { ! methods.put(method.getMethod().getID(), method); } *************** *** 119,124 **** * or <code>null</code> if such method does not exist. */ ! public AllocTypeMethodData getMethod(int ID) { ! return (AllocTypeMethodData)methods.get(new Integer(ID)); } --- 119,124 ---- * or <code>null</code> if such method does not exist. */ ! public AllocTypeMethodData getMethod(Integer ID) { ! return (AllocTypeMethodData)methods.get(ID); } *************** *** 140,144 **** if( threads == Collections.EMPTY_MAP ) threads = new HashMap(); ! threads.put(new Integer(thread.getThread().getID()), thread); } --- 140,144 ---- if( threads == Collections.EMPTY_MAP ) threads = new HashMap(); ! threads.put(thread.getThread().getID(), thread); } *************** *** 151,156 **** * were allocated or <code>null</code> if such thread does not exist. */ ! public AllocThreadTypeData getThread(int ID) { ! return (AllocThreadTypeData)methods.get(new Integer(ID)); } --- 151,156 ---- * were allocated or <code>null</code> if such thread does not exist. */ ! public AllocThreadTypeData getThread(Integer ID) { ! return (AllocThreadTypeData)methods.get(ID); } *************** *** 159,162 **** --- 159,165 ---- /* * $Log$ + * Revision 1.5 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.4 2002/03/01 11:40:12 vachis * doc changes Index: AllocTypeMethodData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocTypeMethodData.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** AllocTypeMethodData.java 1 Mar 2002 11:40:12 -0000 1.2 --- AllocTypeMethodData.java 3 Mar 2002 01:20:08 -0000 1.3 *************** *** 56,60 **** * @param method allocation data for this method. */ ! AllocTypeMethodData(int ID, AllocTypeData type, MethodData method) { super(ID); this.type=type; --- 56,60 ---- * @param method allocation data for this method. */ ! AllocTypeMethodData(Integer ID, AllocTypeData type, MethodData method) { super(ID); this.type=type; *************** *** 72,76 **** */ AllocTypeMethodData( IProf.sID sid, AllocTypeData type, MethodData method ) { ! this( sid.objId, type, method ); //if (sid.alloc!=null) //do not test this, its an error --- 72,76 ---- */ AllocTypeMethodData( IProf.sID sid, AllocTypeData type, MethodData method ) { ! this( new Integer(sid.objId), type, method ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 113,117 **** */ void addTrace(AllocTypeTraceData trace) { ! traces.put(new Integer(trace.getTrace().getID()), trace); } --- 113,117 ---- */ void addTrace(AllocTypeTraceData trace) { ! traces.put(trace.getTrace().getID(), trace); } *************** *** 124,129 **** * type were allocated or <code>null</code> if such trace does not exist. */ ! public AllocTypeTraceData getTrace(int ID) { ! return (AllocTypeTraceData)traces.get(new Integer(ID)); } --- 124,129 ---- * type were allocated or <code>null</code> if such trace does not exist. */ ! public AllocTypeTraceData getTrace(Integer ID) { ! return (AllocTypeTraceData)traces.get( ID ); } *************** *** 146,150 **** */ void addThread(AllocThreadTypeMethodData thread) { ! threads.put(new Integer(thread.getThreadType().getThread().getID()), thread); } --- 146,150 ---- */ void addThread(AllocThreadTypeMethodData thread) { ! threads.put(thread.getThreadType().getThread().getID(), thread); } *************** *** 157,162 **** * of this type allocated or <code>null</code> if such thread does not exist. */ ! public AllocThreadTypeMethodData getThread(int ID) { ! return (AllocThreadTypeMethodData)threads.get(new Integer(ID)); } --- 157,162 ---- * of this type allocated or <code>null</code> if such thread does not exist. */ ! public AllocThreadTypeMethodData getThread(Integer ID) { ! return (AllocThreadTypeMethodData)threads.get( ID ); } *************** *** 165,168 **** --- 165,171 ---- /* * $Log$ + * Revision 1.3 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.2 2002/03/01 11:40:12 vachis * doc changes Index: AllocTypeTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocTypeTraceData.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** AllocTypeTraceData.java 1 Mar 2002 11:40:12 -0000 1.2 --- AllocTypeTraceData.java 3 Mar 2002 01:20:08 -0000 1.3 *************** *** 48,52 **** * @param trace allocation data for this trace. */ ! AllocTypeTraceData(int ID, AllocTypeMethodData typeMethod, AllocTraceData trace) { super(ID); --- 48,52 ---- * @param trace allocation data for this trace. */ ! AllocTypeTraceData(Integer ID, AllocTypeMethodData typeMethod, AllocTraceData trace) { super(ID); *************** *** 64,68 **** AllocTypeTraceData( IProf.sID sid, AllocTypeMethodData classMethod, AllocTraceData trace) { ! this( sid.objId, classMethod, trace ); //if (sid.alloc!=null) //do not test this, its an error --- 64,68 ---- AllocTypeTraceData( IProf.sID sid, AllocTypeMethodData classMethod, AllocTraceData trace) { ! this( new Integer(sid.objId), classMethod, trace ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 105,109 **** */ void addThread(AllocThreadTypeTraceData thread) { ! threads.put(new Integer(thread.getThreadTrace().getThreadMethod().getThread().getID()), thread); } --- 105,109 ---- */ void addThread(AllocThreadTypeTraceData thread) { ! threads.put( thread.getThreadTrace().getThreadMethod().getThread().getID(), thread); } *************** *** 117,122 **** * not exist. */ ! public AllocThreadTypeTraceData getThread(int ID) { ! return (AllocThreadTypeTraceData)threads.get(new Integer(ID)); } --- 117,122 ---- * not exist. */ ! public AllocThreadTypeTraceData getThread(Integer ID) { ! return (AllocThreadTypeTraceData)threads.get(ID); } *************** *** 125,128 **** --- 125,131 ---- /* * $Log$ + * Revision 1.3 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.2 2002/03/01 11:40:12 vachis * doc changes Index: CPUStatIDObjectData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/CPUStatIDObjectData.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** CPUStatIDObjectData.java 20 Nov 2001 22:23:37 -0000 1.3 --- CPUStatIDObjectData.java 3 Mar 2002 01:20:08 -0000 1.4 *************** *** 39,43 **** * @param ID unique ID. */ ! public CPUStatIDObjectData(int ID) { super(ID); } --- 39,43 ---- * @param ID unique ID. */ ! public CPUStatIDObjectData(Integer ID) { super(ID); } *************** *** 76,79 **** --- 76,82 ---- /* * $Log$ + * Revision 1.4 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.3 2001/11/20 22:23:37 vachis * Contructors from IProf.sID and monitors statistic info *************** *** 87,89 **** * Lists changed to Maps. * ! */ \ No newline at end of file --- 90,92 ---- * Lists changed to Maps. * ! */ Index: CPUThreadMethodData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/CPUThreadMethodData.java,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -r1.6 -r1.7 *** CPUThreadMethodData.java 11 Jan 2002 22:22:16 -0000 1.6 --- CPUThreadMethodData.java 3 Mar 2002 01:20:08 -0000 1.7 *************** *** 48,52 **** * @param method profiling data for this method. */ ! CPUThreadMethodData(int ID, ThreadData thread, MethodData method) { super(ID); this.thread=thread; --- 48,52 ---- * @param method profiling data for this method. */ ! CPUThreadMethodData(Integer ID, ThreadData thread, MethodData method) { super(ID); this.thread=thread; *************** *** 63,67 **** */ CPUThreadMethodData( IProf.sID sid, ThreadData thread, MethodData method ) { ! this( sid.objId, thread, method ); //if (sid.cpu!=null) //do not test this, its an error --- 63,67 ---- */ CPUThreadMethodData( IProf.sID sid, ThreadData thread, MethodData method ) { ! this( new Integer(sid.objId), thread, method ); //if (sid.cpu!=null) //do not test this, its an error *************** *** 102,106 **** */ void addTrace(CPUThreadTraceData trace) { ! traces.put(new Integer(trace.getTrace().getID()), trace); } --- 102,106 ---- */ void addTrace(CPUThreadTraceData trace) { ! traces.put( trace.getTrace().getID(), trace); } *************** *** 112,117 **** * if such trace does not exist. */ ! public CPUThreadTraceData getTrace(int ID) { ! return (CPUThreadTraceData)traces.get(new Integer(ID)); } --- 112,117 ---- * if such trace does not exist. */ ! public CPUThreadTraceData getTrace(Integer ID) { ! return (CPUThreadTraceData)traces.get(ID); } *************** *** 120,123 **** --- 120,126 ---- /* * $Log$ + * Revision 1.7 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.6 2002/01/11 22:22:16 vachis * unnecessary test removed *************** *** 140,142 **** * Lists changed to Maps. * ! */ \ No newline at end of file --- 143,145 ---- * Lists changed to Maps. * ! */ Index: CPUThreadTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/CPUThreadTraceData.java,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** CPUThreadTraceData.java 11 Jan 2002 22:22:16 -0000 1.5 --- CPUThreadTraceData.java 3 Mar 2002 01:20:08 -0000 1.6 *************** *** 40,44 **** * @param trace profiling data for this trace. */ ! CPUThreadTraceData(int ID, CPUThreadMethodData threadMethod, CPUTraceData trace) { super(ID); --- 40,44 ---- * @param trace profiling data for this trace. */ ! CPUThreadTraceData(Integer ID, CPUThreadMethodData threadMethod, CPUTraceData trace) { super(ID); *************** *** 56,60 **** CPUThreadTraceData( IProf.sID sid, CPUThreadMethodData threadMethod, CPUTraceData trace ) { ! this( sid.objId, threadMethod, trace ); //if (sid.cpu!=null) //do not test this, its an error --- 56,60 ---- CPUThreadTraceData( IProf.sID sid, CPUThreadMethodData threadMethod, CPUTraceData trace ) { ! this( new Integer(sid.objId), threadMethod, trace ); //if (sid.cpu!=null) //do not test this, its an error *************** *** 84,87 **** --- 84,90 ---- /* * $Log$ + * Revision 1.6 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.5 2002/01/11 22:22:16 vachis * unnecessary test removed *************** *** 101,103 **** * Lists changed to Maps. * ! */ \ No newline at end of file --- 104,106 ---- * Lists changed to Maps. * ! */ Index: CPUTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/CPUTraceData.java,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -r1.7 -r1.8 *** CPUTraceData.java 11 Jan 2002 22:22:16 -0000 1.7 --- CPUTraceData.java 3 Mar 2002 01:20:08 -0000 1.8 *************** *** 52,56 **** * <code>List</code> of {@link TraceFrameData} objects. */ ! CPUTraceData(int ID, MethodData method, List frames) { super(ID); this.method=method; --- 52,56 ---- * <code>List</code> of {@link TraceFrameData} objects. */ ! CPUTraceData(Integer ID, MethodData method, List frames) { super(ID); this.method=method; *************** *** 66,70 **** */ CPUTraceData( IProf.sID sid, MethodData method, List frames ) { ! this( sid.objId, method, frames ); //if (sid.cpu!=null) //do not test this, its an error --- 66,70 ---- */ CPUTraceData( IProf.sID sid, MethodData method, List frames ) { ! this( new Integer(sid.objId), method, frames ); //if (sid.cpu!=null) //do not test this, its an error *************** *** 105,109 **** */ void addThread(CPUThreadTraceData thread) { ! threads.put(new Integer(thread.getThreadMethod().getThread().getID()), thread); } --- 105,109 ---- */ void addThread(CPUThreadTraceData thread) { ! threads.put(thread.getThreadMethod().getThread().getID(), thread); } *************** *** 115,120 **** * or <code>null</code> if such thread does not exist. */ ! public CPUThreadTraceData getThread(int ID) { ! return (CPUThreadTraceData)threads.get(new Integer(ID)); } --- 115,120 ---- * or <code>null</code> if such thread does not exist. */ ! public CPUThreadTraceData getThread(Integer ID) { ! return (CPUThreadTraceData)threads.get(ID); } *************** *** 123,126 **** --- 123,129 ---- /* * $Log$ + * Revision 1.8 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.7 2002/01/11 22:22:16 vachis * unnecessary test removed *************** *** 146,148 **** * Lists changed to Maps. * ! */ \ No newline at end of file --- 149,151 ---- * Lists changed to Maps. * ! */ Index: ClassData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/ClassData.java,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -r1.8 -r1.9 *** ClassData.java 26 Jan 2002 20:56:59 -0000 1.8 --- ClassData.java 3 Mar 2002 01:20:08 -0000 1.9 *************** *** 77,81 **** */ // * @param numMethods number of methods defined in this class. ! ClassData(int ID, String name, String sourceName, int numInterfaces, /*int numMethods,*/ int numStaticFields, List staticFields, int numInstanceFields, List instanceFields, boolean active) { --- 77,81 ---- */ // * @param numMethods number of methods defined in this class. ! ClassData(Integer ID, String name, String sourceName, int numInterfaces, /*int numMethods,*/ int numStaticFields, List staticFields, int numInstanceFields, List instanceFields, boolean active) { *************** *** 107,111 **** ClassData( IProf.sID sid, int numStaticFields, List staticFields, int numInstanceFields, List instanceFields ) { ! this(sid.objId, ((IProf.sClassInfo)sid.info).className, ((IProf.sClassInfo)sid.info).sourceName, ((IProf.sClassInfo)sid.info).numInterfaces,// 0, --- 107,111 ---- ClassData( IProf.sID sid, int numStaticFields, List staticFields, int numInstanceFields, List instanceFields ) { ! this( new Integer(sid.objId), ((IProf.sClassInfo)sid.info).className, ((IProf.sClassInfo)sid.info).sourceName, ((IProf.sClassInfo)sid.info).numInterfaces,// 0, *************** *** 121,125 **** */ ClassData( IProf.sID sid ) { ! this(sid.objId, ((IProf.sClassInfo)sid.info).className, ((IProf.sClassInfo)sid.info).sourceName, ((IProf.sClassInfo)sid.info).numInterfaces,// 0, --- 121,125 ---- */ ClassData( IProf.sID sid ) { ! this( new Integer(sid.objId), ((IProf.sClassInfo)sid.info).className, ((IProf.sClassInfo)sid.info).sourceName, ((IProf.sClassInfo)sid.info).numInterfaces,// 0, *************** *** 268,271 **** --- 268,274 ---- /* * $Log$ + * Revision 1.9 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.8 2002/01/26 20:56:59 vachis * fix getmethods(), get..instaces() returns null *************** *** 294,296 **** * no message * ! */ \ No newline at end of file --- 297,299 ---- * no message * ! */ Index: ClassFieldData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/ClassFieldData.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** ClassFieldData.java 9 Dec 2001 23:23:18 -0000 1.3 --- ClassFieldData.java 3 Mar 2002 01:20:08 -0000 1.4 *************** *** 41,45 **** * @param signature signature of the field. */ ! ClassFieldData(int ID, String name, String signature) { super(ID); this.name=name; --- 41,45 ---- * @param signature signature of the field. */ ! ClassFieldData(Integer ID, String name, String signature) { super(ID); this.name=name; *************** *** 53,57 **** */ ClassFieldData( IProf.sID sid ) { ! this(sid.objId, ((IProf.sClassFieldInfo) sid.info).fieldName, ((IProf.sClassFieldInfo) sid.info).fieldSignature); } --- 53,57 ---- */ ClassFieldData( IProf.sID sid ) { ! this( new Integer(sid.objId), ((IProf.sClassFieldInfo) sid.info).fieldName, ((IProf.sClassFieldInfo) sid.info).fieldSignature); } *************** *** 79,82 **** --- 79,85 ---- /* * $Log$ + * Revision 1.4 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.3 2001/12/09 23:23:18 vachis * constructor for IProf.sid *************** *** 88,90 **** * no message * ! */ \ No newline at end of file --- 91,93 ---- * no message * ! */ Index: GCData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/GCData.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -r1.4 -r1.5 *** GCData.java 2 Dec 2001 14:48:06 -0000 1.4 --- GCData.java 3 Mar 2002 01:20:08 -0000 1.5 *************** *** 49,53 **** * @param endTime time when GC finished. */ ! GCData(int ID, long usedObjects, long usedSpace, long totalSpace, long startTime, long endTime) { super(ID); --- 49,53 ---- * @param endTime time when GC finished. */ ! GCData(Integer ID, long usedObjects, long usedSpace, long totalSpace, long startTime, long endTime) { super(ID); *************** *** 65,69 **** */ GCData( IProf.sID sid ) { ! this(sid.objId, ((IProf.sGCInfo)sid.info).usedObjects, ((IProf.sGCInfo)sid.info).usedObjectSpace, ((IProf.sGCInfo)sid.info).totalObjectSpace, --- 65,69 ---- */ GCData( IProf.sID sid ) { ! this( new Integer(sid.objId), ((IProf.sGCInfo)sid.info).usedObjects, ((IProf.sGCInfo)sid.info).usedObjectSpace, ((IProf.sGCInfo)sid.info).totalObjectSpace, *************** *** 121,124 **** --- 121,127 ---- /* * $Log$ + * Revision 1.5 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.4 2001/12/02 14:48:06 petrul * changed constructor code *************** *** 133,135 **** * no message * ! */ \ No newline at end of file --- 136,138 ---- * no message * ! */ Index: IDObjectData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/IDObjectData.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -r1.4 -r1.5 *** IDObjectData.java 8 Feb 2002 13:18:38 -0000 1.4 --- IDObjectData.java 3 Mar 2002 01:20:08 -0000 1.5 *************** *** 30,34 **** public abstract class IDObjectData implements Serializable { /** Unique ID. */ ! private int ID; /** --- 30,34 ---- public abstract class IDObjectData implements Serializable { /** Unique ID. */ ! private Integer ID; /** *************** *** 37,41 **** * @param ID unique ID. */ ! protected IDObjectData(int ID) { this.ID=ID; } --- 37,41 ---- * @param ID unique ID. */ ! protected IDObjectData(Integer ID) { this.ID=ID; } *************** *** 46,50 **** * @return ID of the object. */ ! public int getID() { return ID; } --- 46,50 ---- * @return ID of the object. */ ! public Integer getID() { return ID; } *************** *** 64,67 **** --- 64,70 ---- /* * $Log$ + * Revision 1.5 2002/03/03 01:20:08 vachis + * type of ID changed from int to Integer + * * Revision 1.4 2002/02/08 13:18:38 petrul * implements Serializable *************** *** 76,78 **** * no message * ! */ \ No newline at end of file --- 79,81 ---- * no message * ! */ Index: MethodData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/MethodData.java,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -r1.14 -r1.15 *** MethodData.java 1 Mar 2002 11:41:43 -0000 1.14 --- MethodData.java 3 Mar 2002 01:20:09 -0000 1.15 *************** *** 108,112 **** * @param clazz class this method belongs to. */ ! MethodData(int ID, String name, String signature, int startLine, int endLine, ClassData clazz) { super(ID); --- 108,112 ---- * @param clazz class this method belongs to. */ ! MethodData(Integer ID, String name, String signature, int startLine, int endLine, ClassData clazz) { super(ID); *************** *** 135,139 **** */ MethodData( IProf.sID sid, ClassData clazz ) { ! this(sid.objId, ((IProf.sMethodInfo)sid.info).methodName, ((IProf.sMethodInfo)sid.info).methodSignature, ((IProf.sMethodInfo)sid.info).startLineno, --- 135,139 ---- */ MethodData( IProf.sID sid, ClassData clazz ) { ! this( new Integer(sid.objId), ((IProf.sMethodInfo)sid.info).methodName, ((IProf.sMethodInfo)sid.info).methodSignature, ((IProf.sMethodInfo)sid.info).startLineno, *************** *** 215,219 **** if ( allocTraces == Collections.EMPTY_MAP ) allocTraces = new HashMap(); ! allocTraces.put(new Integer(trace.getID()), trace); } --- 215,219 ---- if ( allocTraces == Collections.EMPTY_MAP ) allocTraces = new HashMap(); ! allocTraces.put(trace.getID(), trace); } *************** *** 226,231 **** * were allocated or <code>null</code> if such trace does not exist. */ ! public AllocTraceData getAllocTrace(int ID) { ! return (AllocTraceData)allocTraces.get(new Integer(ID)); } --- 226,231 ---- * were allocated or <code>null</code> if such trace does not exist. */ ! public AllocTraceData getAllocTrace(Integer ID) { ! return (AllocTraceData)allocTraces.get(ID); } *************** *** 247,251 **** if ( CPUTraces == Collections.EMPTY_MAP ) CPUTraces = new HashMap(); ! CPUTraces.put(new Integer(trace.getID()), trace); } --- 247,251 ---- if ( CPUTraces == Collections.EMPTY_MAP ) CPUTraces = new HashMap(); ! CPUTraces.put(trace.getID(), trace); } *************** *** 257,262 **** * if such trace does not exist. */ ! public CPUTraceData getCPUTrace(int ID) { ! return (CPUTraceData)CPUTraces.get(new Integer(ID)); } --- 257,262 ---- * if such trace does not exist. */ ! public CPUTraceData getCPUTrace(Integer ID) { ! return (CPUTraceData)CPUTraces.get(ID); } *************** *** 278,282 **** if ( MonTraces == Collections.EMPTY_MAP ) MonTraces = new HashMap(); ! MonTraces.put(new Integer(trace.getID()), trace); } --- 278,282 ---- if ( MonTraces == Collections.EMPTY_MAP ) MonTraces = new HashMap(); ! MonTraces.put(trace.getID(), trace); } *************** *** 288,293 **** * if such trace does not exist. */ ! public MonTraceData getMonTrace(int ID) { ! return (MonTraceData)MonTraces.get(new Integer(ID)); } --- 288,293 ---- * if such trace does not exist. */ ! public MonTraceData getMonTrace(Integer ID) { ! return (MonTraceData)MonTraces.get(ID); } *************** *** 310,314 **** if ( types == Collections.EMPTY_MAP ) types = new HashMap(); ! types.put(new Integer(allocType.getID()), allocType); } --- 310,314 ---- if ( types == Collections.EMPTY_MAP ) types = new HashMap(); ! types.put(allocType.getID(), allocType); } *************** *** 321,326 **** * in this method or <code>null</code> if such class does not exist. */ ! public AllocTypeMethodData getType(int ID) { ! return (AllocTypeMethodData)types.get(new Integer(ID)); } --- 321,326 ---- * in this method or <code>null</code> if such class does not exist. */ ! public AllocTypeMethodData getType(Integer ID) { ! return (AllocTypeMethodData)types.get(ID); } *************** *** 355,360 **** * or <code>null</code> if such thread does not exist. */ ! public AllocThreadMethodData getAllocThread(int ID) { ! return (AllocThreadMethodData) allocThreads.get(new Integer(ID)); } --- 355,360 ---- * or <code>null</code> if such thread does not exist. */ ! public AllocThreadMethodData getAllocThread(Integer ID) { ! return (AllocThreadMethodData) allocThreads.get(ID); } *************** *** 376,380 **** if ( CPUThreads == Collections.EMPTY_MAP ) CPUThreads = new HashMap(); ! CPUThreads.put(new Integer(thread.getThread().getID()), thread); } --- 376,380 ---- if ( CPUThreads == Collections.EMPTY_MAP ) CPUThreads = new HashMap(); ! CPUThreads.put(thread.getThread().getID(), thread); } *************** *** 386,391 **** * or <code>null</code> if such thread does not exist. */ ! public CPUThreadMethodData getCPUThread(int ID) { ! return (CPUThreadMethodData)CPUThreads.get(new Integer(ID)); } --- 386,391 ---- * or <code>null</code> if such thread does not exist. */ ! public CPUThreadMethodData getCPUThread(Integer ID) { ! return (CPUThreadMethodData)CPUThreads.get(ID); } *************** *** 407,411 **** if ( MonThreads == Collections.EMPTY_MAP ) MonThreads = new HashMap(); ! MonThreads.put(new Integer(thread.getThread().getID()), thread); } --- 407,411 ---- if ( MonThreads == Collections.EMPTY_MAP ) MonThreads = new HashMap(); ! MonThreads.put(thread.getThread().getID(), thread); } *************** *** 417,422 **** * or <code>null</code> if such thread does not exist. */ ! public MonThreadMethodData getMonThread(int ID) { ! return (MonThreadMethodData)CPUThreads.get(new Integer(ID)); } --- 417,422 ---- * or <code>null</code> if such thread does not exist. */ ! public MonThreadMethodData getMonThread(Integer ID) { ! return (MonThreadMethodData)CPUThreads.get(ID); } *************** *** 548,551 **** --- 548,554 ---- /* * $Log$ + * Revision 1.15 2002/03/03 01:20:09 vachis + * type of ID changed from int to Integer + * * Revision 1.14 2002/03/01 11:41:43 vachis * doc changes Index: MonStatIDObjectData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/MonStatIDObjectData.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** MonStatIDObjectData.java 20 Nov 2001 22:28:50 -0000 1.1 --- MonStatIDObjectData.java 3 Mar 2002 01:20:09 -0000 1.2 *************** *** 34,38 **** /** Creates new MonStatIDObjectData */ ! public MonStatIDObjectData(int ID) { super(ID); } --- 34,38 ---- /** Creates new MonStatIDObjectData */ ! public MonStatIDObjectData(Integer ID) { super(ID); } *************** *** 71,74 **** --- 71,77 ---- /* * $Log$ + * Revision 1.2 2002/03/03 01:20:09 vachis + * type of ID changed from int to Integer + * * Revision 1.1 2001/11/20 22:28:50 vachis * Monitors data classes Index: MonThreadMethodData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/MonThreadMethodData.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** MonThreadMethodData.java 11 Jan 2002 22:22:16 -0000 1.3 --- MonThreadMethodData.java 3 Mar 2002 01:20:09 -0000 1.4 *************** *** 49,53 **** * @param method profiling data for this method. */ ! public MonThreadMethodData(int ID, ThreadData thread, MethodData method) { super(ID); this.thread=thread; --- 49,53 ---- * @param method profiling data for this method. */ ! public MonThreadMethodData(Integer ID, ThreadData thread, MethodData method) { super(ID); this.thread=thread; *************** *** 64,68 **** */ MonThreadMethodData( IProf.sID sid, ThreadData thread, MethodData method ) { ! this( sid.objId, thread, method ); //if (sid.mon!=null) //do not test this, its an error --- 64,68 ---- */ MonThreadMethodData( IProf.sID sid, ThreadData thread, MethodData method ) { ! this( new Integer(sid.objId), thread, method ); //if (sid.mon!=null) //do not test this, its an error *************** *** 103,107 **** */ void addTrace(MonThreadTraceData trace) { ! traces.put(new Integer(trace.getTrace().getID()), trace); } --- 103,107 ---- */ void addTrace(MonThreadTraceData trace) { ! traces.put(trace.getTrace().getID(), trace); } *************** *** 113,118 **** * if such trace does not exist. */ ! public MonThreadTraceData getTrace(int ID) { ! return (MonThreadTraceData)traces.get(new Integer(ID)); } --- 113,118 ---- * if such trace does not exist. */ ! public MonThreadTraceData getTrace(Integer ID) { ! return (MonThreadTraceData)traces.get(ID); } *************** *** 122,125 **** --- 122,128 ---- /* * $Log$ + * Revision 1.4 2002/03/03 01:20:09 vachis + * type of ID changed from int to Integer + * * Revision 1.3 2002/01/11 22:22:16 vachis * unnecessary test removed Index: MonThreadTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/MonThreadTraceData.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** MonThreadTraceData.java 11 Jan 2002 22:22:16 -0000 1.3 --- MonThreadTraceData.java 3 Mar 2002 01:20:09 -0000 1.4 *************** *** 45,49 **** * @param trace profiling data for this trace. */ ! MonThreadTraceData(int ID, MonThreadMethodData threadMethod, MonTraceData trace) { super(ID); --- 45,49 ---- * @param trace profiling data for this trace. */ ! MonThreadTraceData(Integer ID, MonThreadMethodData threadMethod, MonTraceData trace) { super(ID); *************** *** 61,65 **** MonThreadTraceData( IProf.sID sid, MonThreadMethodData threadMethod, MonTraceData trace ) { ! this( sid.objId, threadMethod, trace ); //if (sid.mon!=null) //do not test this, its an error --- 61,65 ---- MonThreadTraceData( IProf.sID sid, MonThreadMethodData threadMethod, MonTraceData trace ) { ! this( new Integer(sid.objId), threadMethod, trace ); //if (sid.mon!=null) //do not test this, its an error *************** *** 89,92 **** --- 89,95 ---- /* * $Log$ + * Revision 1.4 2002/03/03 01:20:09 vachis + * type of ID changed from int to Integer + * * Revision 1.3 2002/01/11 22:22:16 vachis * unnecessary test removed *************** *** 98,100 **** * Monitors data classes * ! */ \ No newline at end of file --- 101,103 ---- * Monitors data classes * ! */ Index: MonTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/MonTraceData.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -r1.4 -r1.5 *** MonTraceData.java 11 Jan 2002 22:22:16 -0000 1.4 --- MonTraceData.java 3 Mar 2002 01:20:09 -0000 1.5 *************** *** 54,58 **** * <code>List</code> of {@link TraceFrameData} objects. */ ! MonTraceData(int ID, MethodData method, List frames) { super(ID); this.method=method; --- 54,58 ---- * <code>List</code> of {@link TraceFrameData} objects. */ ! MonTraceData(Integer ID, MethodData method, List frames) { super(ID); this.method=method; *************** *** 68,72 **** */ MonTraceData( IProf.sID sid, MethodData method, List frames ) { ! this( sid.objId, method, frames ); //if (sid.mon!=null) //do not test this, its an error --- 68,72 ---- */ MonTraceData( IProf.sID sid, MethodData method, List frames ) { ! this( new Integer(sid.objId), method, frames ); //if (sid.mon!=null) //do not test this, its an error *************** *** 108,112 **** */ void addThread(MonThreadTraceData thread) { ! threads.put(new Integer(thread.getThreadMethod().getThread().getID()), thread); } --- 108,112 ---- */ void addThread(MonThreadTraceData thread) { ! threads.put(thread.getThreadMethod().getThread().getID(), thread); } *************** *** 118,123 **** * or <code>null</code> if such thread does not exist. */ ! public MonThreadTraceData getThread(int ID) { ! return (MonThreadTraceData)threads.get(new Integer(ID)); } } --- 118,123 ---- * or <code>null</code> if such thread does not exist. */ ! public MonThreadTraceData getThread(Integer ID) { ! return (MonThreadTraceData)threads.get(ID); } } *************** *** 126,129 **** --- 126,132 ---- /* * $Log$ + * Revision 1.5 2002/03/03 01:20:09 vachis + * type of ID changed from int to Integer + * * Revision 1.4 2002/01/11 22:22:16 vachis * unnecessary test removed *************** *** 138,140 **** * Monitors data classes * ! */ \ No newline at end of file --- 141,143 ---- * Monitors data classes * ! */ Index: SnapshotImpl.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/SnapshotImpl.java,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -r1.11 -r1.12 *** SnapshotImpl.java 16 Feb 2002 16:21:52 -0000 1.11 --- SnapshotImpl.java 3 Mar 2002 01:20:09 -0000 1.12 *************** *** 502,506 **** else{ obj = (IDObjectData) iter.next(); ! iterInner = iprof.getAllThruIterator( obj.getID(), whatType, true, IProf.isObjWithInfo( whatType), optArg ); } --- 502,506 ---- else{ obj = (IDObjectData) iter.next(); ! iterInner = iprof.getAllThruIterator( obj.getID().intValue(), whatType, true, IProf.isObjWithInfo( whatType), optArg ); } *************** *** 517,521 **** objInner = createAndPutIn( whatType, sid, obj, postOpLst, postOpIterLst ); ! libIDs.put( new Integer(objInner.getID()), objInner ); if ( out != null ) out.add( objInner ); --- 517,521 ---- objInner = createAndPutIn( whatType, sid, obj, postOpLst, postOpIterLst ); ! libIDs.put( objInner.getID(), objInner ); if ( out != null ) out.add( objInner ); *************** *** 1036,1039 **** --- 1036,1042 ---- /* * $Log$ + * Revision 1.12 2002/03/03 01:20:09 vachis + ... [truncated message content] |
From: Pavel V. <va...@us...> - 2002-03-03 00:28:39
|
Update of /cvsroot/javaprofiler/test/snapshot In directory usw-pr-cvs1:/tmp/cvs-serv7374 Modified Files: run3.bat run2.bat run1.bat Log Message: no message Index: run3.bat =================================================================== RCS file: /cvsroot/javaprofiler/test/snapshot/run3.bat,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** run3.bat 22 Feb 2002 13:33:33 -0000 1.1 --- run3.bat 3 Mar 2002 00:28:35 -0000 1.2 *************** *** 1,3 **** ! SET JAVA_HOME=d:\j2sdk1.4.0-rc rem ************************** SET CLASSPATH=.;%CLASSPATH% --- 1,3 ---- ! SET JAVA_HOME=d:\programs\j2sdk1.4.0 rem ************************** SET CLASSPATH=.;%CLASSPATH% Index: run2.bat =================================================================== RCS file: /cvsroot/javaprofiler/test/snapshot/run2.bat,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** run2.bat 26 Jan 2002 19:37:10 -0000 1.3 --- run2.bat 3 Mar 2002 00:28:35 -0000 1.4 *************** *** 1,5 **** ! SET JAVA_HOME=d:\j2sdk1.4.0-rc rem ************************** SET CLASSPATH=%JAVA_HOME%\demo\jfc\SwingSet2\SwingSet2.jar;%CLASSPATH% set path=%JAVA_HOME%\bin;%path% ! java -Xrun..\..\library\src\profiler\profiler:commun_type=socket SwingSet2 --- 1,5 ---- ! SET JAVA_HOME=d:\programs\j2sdk1.4.0 rem ************************** SET CLASSPATH=%JAVA_HOME%\demo\jfc\SwingSet2\SwingSet2.jar;%CLASSPATH% set path=%JAVA_HOME%\bin;%path% ! java -Xrun..\..\library\src\profiler\profiler:commun_type=socket SwingSet2 > out2.txt Index: run1.bat =================================================================== RCS file: /cvsroot/javaprofiler/test/snapshot/run1.bat,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** run1.bat 8 Feb 2002 10:59:48 -0000 1.5 --- run1.bat 3 Mar 2002 00:28:35 -0000 1.6 *************** *** 1,3 **** ! SET JAVA_HOME=d:\j2sdk1.4.0-rc rem ************************** SET CLASSPATH=%JAVA_HOME%\demo\jfc\Notepad\Notepad.jar;%CLASSPATH% --- 1,3 ---- ! SET JAVA_HOME=d:\programs\j2sdk1.4.0 rem ************************** SET CLASSPATH=%JAVA_HOME%\demo\jfc\Notepad\Notepad.jar;%CLASSPATH% |
From: Pavel V. <va...@us...> - 2002-03-03 00:26:36
|
Update of /cvsroot/javaprofiler/test/snapshot In directory usw-pr-cvs1:/tmp/cvs-serv6697/test/snapshot Modified Files: PrintSnap.java TestNoSwing.java Log Message: output to err Index: PrintSnap.java =================================================================== RCS file: /cvsroot/javaprofiler/test/snapshot/PrintSnap.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** PrintSnap.java 30 Jan 2002 00:23:20 -0000 1.2 --- PrintSnap.java 3 Mar 2002 00:26:30 -0000 1.3 *************** *** 81,103 **** //iprof = new IProf(); iprof = new IProf( new CommunSetupSocket() ); ! ! iprof.run(); try { ! System.out.println( "Ready" ); ! // til profiled program is going, do nothing ! while( !iprof.isShutdowned()) Thread.sleep( 1000); ! System.out.println( "DebugOut START" ); ! printSnapShot(); ! System.out.println( "DebugOut END" ); ! iprof.shutdown(); } catch( Exception e) { ! System.err.println( "an error occurred, exception:"); ! System.err.println( e.getClass().getName()); } --- 81,107 ---- //iprof = new IProf(); iprof = new IProf( new CommunSetupSocket() ); ! //iprof = new IProf( new CommunSetupShMem() ); ! ! if ( !iprof.run() ) { ! System.err.println("Error in communication"); ! return; ! } try { ! System.err.println( "Ready" ); ! // til profiled program is going, do nothing ! while( !iprof.isShutdowned()) Thread.sleep( 1000); ! System.err.println( "DebugOut START" ); ! printSnapShot(); ! System.err.println( "DebugOut END" ); ! iprof.shutdown(); } catch( Exception e) { ! System.err.println( "an error occurred, exception:"); ! System.err.println( e.getClass().getName()); } Index: TestNoSwing.java =================================================================== RCS file: /cvsroot/javaprofiler/test/snapshot/TestNoSwing.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** TestNoSwing.java 22 Feb 2002 17:16:40 -0000 1.2 --- TestNoSwing.java 3 Mar 2002 00:26:30 -0000 1.3 *************** *** 92,96 **** int i; ! System.out.println( "Start" ); System.err.print("Press a key"); try { --- 92,96 ---- int i; ! System.err.println( "Start" ); System.err.print("Press a key"); try { *************** *** 105,112 **** a.initList(); a.sort(); ! System.out.print( i + " " ); } ! System.out.println( "end." ); System.err.print("Press a key"); try { --- 105,112 ---- a.initList(); a.sort(); ! System.err.print( i + " " ); } ! System.err.println( "end." ); System.err.print("Press a key"); try { |
From: Marek P. <ma...@us...> - 2002-03-02 15:48:48
|
Update of /cvsroot/javaprofiler/library/src/commun In directory usw-pr-cvs1:/tmp/cvs-serv5976/src/commun Modified Files: buffer.h Log Message: communication improvements Index: buffer.h =================================================================== RCS file: /cvsroot/javaprofiler/library/src/commun/buffer.h,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** buffer.h 21 Nov 2001 22:31:42 -0000 1.5 --- buffer.h 2 Mar 2002 15:48:44 -0000 1.6 *************** *** 62,66 **** /// number of bytes reserved in buffer ! RESERVED = 50 }; --- 62,66 ---- /// number of bytes reserved in buffer ! RESERVED = 512*1024 }; |
From: Pavel V. <va...@us...> - 2002-03-01 11:50:29
|
Update of /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data In directory usw-pr-cvs1:/tmp/cvs-serv14651 Removed Files: AllocAbstractStatThreadClassData.java Log Message: rename of class --- AllocAbstractStatThreadClassData.java DELETED --- |
From: Pavel V. <va...@us...> - 2002-03-01 11:49:01
|
Update of /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data In directory usw-pr-cvs1:/tmp/cvs-serv14118 Added Files: AllocAbstractStatThreadTypeData.java Log Message: rename of class --- NEW FILE: AllocAbstractStatThreadTypeData.java --- /* * Sun Public License Notice * * The contents of this file are subject to the Sun Public License Version * 1.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is available at http://www.sun.com/ * * The Original Code is the Java Profiler module. * The Initial Developers of the Original Code are Jan Stola, Pavel Vacha, * Michal Pise, Petr Luner, Lukas Petru and Marek Przeczek. * Portions created by Jan Stola are Copyright (C) 2000-2001. All Rights Reserved. * Portions created by Pavel Vacha are Copyright (C) 2000-2001. All Rights Reserved. * Portions created by Michal Pise are Copyright (C) 2000-2001. All Rights Reserved. * Portions created by Petr Luner are Copyright (C) 2000-2001. All Rights Reserved. * Portions created by Lukas Petru are Copyright (C) 2000-2001. All Rights Reserved. * Portions created by Marek Przeczek are Copyright (C) 2000-2001. All Rights Reserved. * * Contributors: Jan Stola, Pavel Vacha, Michal Pise, Petr Luner, * Lukas Petru and Marek Przeczek. */ package net.sourceforge.javaprofiler.jpiimpl.data; /** * An abstract statistic class for better granularity of profiling. * * @author Jan Stola */ public abstract class AllocAbstractStatThreadTypeData extends AllocStatIDObjectData { /** * Constructor to be used by subclasses. * * @param ID unique ID. */ protected AllocAbstractStatThreadTypeData(int ID) { super(ID); } } /* * $Log: AllocAbstractStatThreadTypeData.java,v $ * Revision 1.1 2002/03/01 11:48:57 vachis * rename of class * * Revision 1.3 2001/09/29 21:01:33 stolis * Plural added in licenses. * * Revision 1.2 2001/07/18 22:20:39 stolis * Mirrors for CPU profiling added; * references to obejct IDs removed; * Lists changed to Maps. * * Revision 1.1.1.1 2001/07/11 22:28:10 stolis * no message * */ |
From: Pavel V. <va...@us...> - 2002-03-01 11:41:46
|
Update of /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data In directory usw-pr-cvs1:/tmp/cvs-serv12851/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data Modified Files: MethodData.java ThreadData.java Log Message: doc changes Index: MethodData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/MethodData.java,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -r1.13 -r1.14 *** MethodData.java 16 Feb 2002 16:21:53 -0000 1.13 --- MethodData.java 1 Mar 2002 11:41:43 -0000 1.14 *************** *** 73,78 **** private Map allocThreads; /** ! * Map of classes whose instances were allocated in this method. ! * Mapping of {@link AllocClassMethodData} objects and class IDs. */ private Map types; --- 73,78 ---- private Map allocThreads; /** ! * Map of types (classes or arrays of classes) whose instances were allocated in this method. ! * Mapping of {@link AllocTypeMethodData} objects and class IDs. */ private Map types; *************** *** 293,299 **** /** ! * Returns map of classes whose instances were allocated in this method. * ! * @return mapping of {@link AllocClassMethodData} objects and class IDs. */ public Map getTypes() { --- 293,299 ---- /** ! * Returns map of types (classes or arrays of classes) whose instances were allocated in this method. * ! * @return mapping of {@link AllocTypeMethodData} objects and type IDs. */ public Map getTypes() { *************** *** 302,322 **** /** ! * Adds allocClass whose were allocated in this method. AllocClass ! * can be instance of class its array. * ! * @param allocClass allocClass that were allocated in this method. */ ! void addType(AllocTypeMethodData allocClass) { if ( types == Collections.EMPTY_MAP ) types = new HashMap(); ! types.put(new Integer(allocClass.getID()), allocClass); } /** ! * Returns class (with given ID) whose instances were allocated * in this method. * ! * @param ID ID of the class. ! * @return class (with given ID) whose instances were allocated * in this method or <code>null</code> if such class does not exist. */ --- 302,322 ---- /** ! * Adds type that was allocated in this method. Type ! * can be instance of class or its array. * ! * @param allocType allocType that was allocated in this method. */ ! void addType(AllocTypeMethodData allocType) { if ( types == Collections.EMPTY_MAP ) types = new HashMap(); ! types.put(new Integer(allocType.getID()), allocType); } /** ! * Returns type (with given ID) whose instances were allocated * in this method. * ! * @param ID ID of the type. ! * @return type (with given ID) whose instances were allocated * in this method or <code>null</code> if such class does not exist. */ *************** *** 548,551 **** --- 548,554 ---- /* * $Log$ + * Revision 1.14 2002/03/01 11:41:43 vachis + * doc changes + * * Revision 1.13 2002/02/16 16:21:53 vachis * code refacorization Class.. to Type... (forgotten methods) Index: ThreadData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/ThreadData.java,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -r1.14 -r1.15 *** ThreadData.java 16 Feb 2002 16:21:52 -0000 1.14 --- ThreadData.java 1 Mar 2002 11:41:43 -0000 1.15 *************** *** 45,50 **** private List children; /** ! * Map of classes whose instances were allocated in this thread. ! * Mapping of {@link AllocThreadClassData} objects and class IDs. */ private Map types; --- 45,50 ---- private List children; /** ! * Map of types (classes or arrays of classes) whose instances were allocated in this thread. ! * Mapping of {@link AllocThreadTypeData} objects and types IDs. */ private Map types; *************** *** 179,185 **** /** ! * Returns map of classes whose instances were allocated in this thread. * ! * @return mapping of {@link AllocThreadClassData} objects and class IDs. */ public Map getTypes() { --- 179,185 ---- /** ! * Returns map of types (classes or arrays of classes) whose instances were allocated in this thread. * ! * @return mapping of {@link AllocThreadTypeData} objects and types IDs. */ public Map getTypes() { *************** *** 188,199 **** /** ! * Adds allocClass whose were allocated in this thread. AllocClass ! * can be instance of class its array. * ! * @param allocClass allocClass that were allocated in this thread. */ ! void addType(AllocThreadTypeData allocClass) { //FIXME: ! types.put(new Integer(allocClass.getID()), allocClass); } --- 188,199 ---- /** ! * Adds type that was allocated in this thread. Type ! * can be instance of class or its array. * ! * @param allocType allocType that were allocated in this thread. */ ! void addType(AllocThreadTypeData allocType) { //FIXME: ! types.put(new Integer(allocType.getID()), allocType); } *************** *** 300,303 **** --- 300,306 ---- /* * $Log$ + * Revision 1.15 2002/03/01 11:41:43 vachis + * doc changes + * * Revision 1.14 2002/02/16 16:21:52 vachis * code refacorization Class.. to Type... (forgotten methods) |
From: Pavel V. <va...@us...> - 2002-03-01 11:40:17
|
Update of /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data In directory usw-pr-cvs1:/tmp/cvs-serv12401/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data Modified Files: AllocInstanceData.java AllocThreadMethodData.java AllocThreadTraceData.java AllocThreadTypeData.java AllocThreadTypeMethodData.java AllocThreadTypeTraceData.java AllocTraceData.java AllocTypeData.java AllocTypeMethodData.java AllocTypeTraceData.java Log Message: doc changes Index: AllocInstanceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocInstanceData.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -r1.4 -r1.5 *** AllocInstanceData.java 29 Sep 2001 21:01:33 -0000 1.4 --- AllocInstanceData.java 1 Mar 2002 11:40:12 -0000 1.5 *************** *** 34,38 **** private AllocArenaData arena; /** Where this instance was allocated. */ ! private AllocAbstractStatThreadClassData location; /** --- 34,38 ---- private AllocArenaData arena; /** Where this instance was allocated. */ ! private AllocAbstractStatThreadTypeData location; /** *************** *** 44,48 **** */ AllocInstanceData(int size, long objectID, AllocArenaData arena, ! AllocAbstractStatThreadClassData location) { this.size=size; this.objectID=objectID; --- 44,48 ---- */ AllocInstanceData(int size, long objectID, AllocArenaData arena, ! AllocAbstractStatThreadTypeData location) { this.size=size; this.objectID=objectID; *************** *** 81,88 **** * Gets location where this instance was allocated. * ! * @return {@link AllocAbstractStatThreadClassData} object determining * location where this instance was allocated. */ ! public AllocAbstractStatThreadClassData getLocation() { return location; } --- 81,88 ---- * Gets location where this instance was allocated. * ! * @return {@link AllocAbstractStatThreadTypeData} object determining * location where this instance was allocated. */ ! public AllocAbstractStatThreadTypeData getLocation() { return location; } *************** *** 92,95 **** --- 92,98 ---- /* * $Log$ + * Revision 1.5 2002/03/01 11:40:12 vachis + * doc changes + * * Revision 1.4 2001/09/29 21:01:33 stolis * Plural added in licenses. *************** *** 106,108 **** * no message * ! */ \ No newline at end of file --- 109,111 ---- * no message * ! */ Index: AllocThreadMethodData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocThreadMethodData.java,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -r1.10 -r1.11 *** AllocThreadMethodData.java 15 Feb 2002 22:37:30 -0000 1.10 --- AllocThreadMethodData.java 1 Mar 2002 11:40:12 -0000 1.11 *************** *** 36,41 **** private MethodData method; /** ! * Map of classes whose instances were allocated in this method and thread. ! * Mapping of {@link AllocThreadClassMethodData} objects and class IDs. */ private Map types; --- 36,41 ---- private MethodData method; /** ! * Map of types (classes or arrays of classes) whose instances were allocated in this method and thread. ! * Mapping of {@link AllocThreaTypeMethodData} objects and class IDs. */ private Map types; *************** *** 94,101 **** /** ! * Returns map of classes whose instances were allocated in this method * and thread. * ! * @return mapping of {@link AllocThreadClassMethodData} objects and class IDs. */ public Map getTypes() { --- 94,101 ---- /** ! * Returns map of types (classes or arrays of classes) whose instances were allocated in this method * and thread. * ! * @return mapping of {@link AllocThreadTypeMethodData} objects and class IDs. */ public Map getTypes() { *************** *** 104,115 **** /** ! * Adds allocClass whose were allocated in this given method ! * and thread. AllocClass can be instance of class its array. * ! * @param allocClass allocClass that were allocated in this method and thread. */ ! void addType(AllocThreadTypeMethodData allocClass) { //FIXME ! types.put(new Integer(allocClass.getID()), allocClass); } --- 104,115 ---- /** ! * Adds types that were allocated in this given method ! * and thread. Type can be instance of class or its array. * ! * @param allocType allocType that were allocated in this method and thread. */ ! void addType(AllocThreadTypeMethodData allocType) { //FIXME ! types.put(new Integer(allocType.getID()), allocType); } *************** *** 118,122 **** * in this method and thread. * ! * @param ID ID of the class. * @return class (with given ID) whose instances were allocated * in this method and thread or <code>null</code> if such class does --- 118,122 ---- * in this method and thread. * ! * @param ID ID of the type. * @return class (with given ID) whose instances were allocated * in this method and thread or <code>null</code> if such class does *************** *** 160,163 **** --- 160,166 ---- /* * $Log$ + * Revision 1.11 2002/03/01 11:40:12 vachis + * doc changes + * * Revision 1.10 2002/02/15 22:37:30 vachis * code refactorization Class..Data renamed to Type..Data Index: AllocThreadTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocThreadTraceData.java,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -r1.10 -r1.11 *** AllocThreadTraceData.java 15 Feb 2002 22:37:30 -0000 1.10 --- AllocThreadTraceData.java 1 Mar 2002 11:40:12 -0000 1.11 *************** *** 36,41 **** private AllocTraceData trace; /** ! * Map of classes whose instances were allocated in the given trace and thread. ! * Mapping of {@link AllocThreadClassTraceData} objects and class IDs. */ private Map types; --- 36,42 ---- private AllocTraceData trace; /** ! * Map of ! types (classes or arrays of classes) whose instances were allocated in the given trace and thread. ! * Mapping of {@link AllocThreadTypeTraceData} objects and class IDs. */ private Map types; *************** *** 88,95 **** /** ! * Returns map of classes whose instances were allocated in the given trace * and thread. * ! * @return mapping of {@link AllocThreadClassTraceData} objects and class IDs. */ public Map getTypes() { --- 89,96 ---- /** ! * Returns map of types (classes or arrays of classes) whose instances were allocated in the given trace * and thread. * ! * @return mapping of {@link AllocThreadTypeTraceData} objects and class IDs. */ public Map getTypes() { *************** *** 98,110 **** /** ! * Adds allocClass whose were allocated in this given trace ! * and thread. AllocClass can be instance of class its array. * ! * @param allocClass allocClass that were allocated in the given trace * and thread. */ ! void addType(AllocThreadTypeTraceData allocClass) { // FIXME: ! types.put(new Integer(allocClass.getID()), allocClass); } --- 99,111 ---- /** ! * Adds type that was allocated in this given trace ! * and thread. type can be instance of class or its array. * ! * @param allocType allocType that was allocated in the given trace * and thread. */ ! void addType(AllocThreadTypeTraceData allocType) { // FIXME: ! types.put(new Integer(allocType.getID()), allocType); } *************** *** 113,117 **** * the given trace and thread. * ! * @param ID ID of the class. * @return class (with given ID) whose instances were allocated in * the given trace and thread or <code>null</code> if such class does --- 114,118 ---- * the given trace and thread. * ! * @param ID ID of the type. * @return class (with given ID) whose instances were allocated in * the given trace and thread or <code>null</code> if such class does *************** *** 126,129 **** --- 127,133 ---- /* * $Log$ + * Revision 1.11 2002/03/01 11:40:12 vachis + * doc changes + * * Revision 1.10 2002/02/15 22:37:30 vachis * code refactorization Class..Data renamed to Type..Data Index: AllocThreadTypeData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocThreadTypeData.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** AllocThreadTypeData.java 15 Feb 2002 22:37:30 -0000 1.1 --- AllocThreadTypeData.java 1 Mar 2002 11:40:12 -0000 1.2 *************** *** 29,36 **** * @author Jan Stola */ ! public class AllocThreadTypeData extends AllocAbstractStatThreadClassData { /** Allocation data for this thread. */ private ThreadData thread; ! /** Allocation data for this class. */ private AllocTypeData type; /** --- 29,36 ---- * @author Jan Stola */ ! public class AllocThreadTypeData extends AllocAbstractStatThreadTypeData { /** Allocation data for this thread. */ private ThreadData thread; ! /** Allocation data for this type. */ private AllocTypeData type; /** *************** *** 41,66 **** /** ! * Creates new AllocThreadClassData. * * @param ID unique ID of this object. * @param thread allocation data for this thread. ! * @param clazz allocation data for this class. */ ! AllocThreadTypeData(int ID, ThreadData thread, AllocTypeData clazz) { super(ID); this.thread=thread; ! this.type=clazz; methods=new HashMap(); } /** ! * Creates new AllocThreadClassdData. * * @param sid data returned by communication layer * @param thread allocation data for this thread. ! * @param clazz allocation data for this class. */ ! AllocThreadTypeData( IProf.sID sid, ThreadData thread, AllocTypeData clazz ) { ! this( sid.objId, thread, clazz ); //if (sid.alloc!=null) //do not test this, its an error --- 41,66 ---- /** ! * Creates new AllocThreadTypeData. * * @param ID unique ID of this object. * @param thread allocation data for this thread. ! * @param type allocation data for this class. */ ! AllocThreadTypeData(int ID, ThreadData thread, AllocTypeData type) { super(ID); this.thread=thread; ! this.type=type; methods=new HashMap(); } /** ! * Creates new AllocThreadTypeData. * * @param sid data returned by communication layer * @param thread allocation data for this thread. ! * @param type allocation data for this type. */ ! AllocThreadTypeData( IProf.sID sid, ThreadData thread, AllocTypeData type ) { ! this( sid.objId, thread, type ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 125,128 **** --- 125,131 ---- /* * $Log$ + * Revision 1.2 2002/03/01 11:40:12 vachis + * doc changes + * * Revision 1.1 2002/02/15 22:37:30 vachis * code refactorization Class..Data renamed to Type..Data Index: AllocThreadTypeMethodData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocThreadTypeMethodData.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** AllocThreadTypeMethodData.java 15 Feb 2002 22:37:30 -0000 1.1 --- AllocThreadTypeMethodData.java 1 Mar 2002 11:40:12 -0000 1.2 *************** *** 30,37 **** * @author Jan Stola */ ! public class AllocThreadTypeMethodData extends AllocAbstractStatThreadClassData { ! /** Allocation data for this class and thread. */ private AllocThreadTypeData threadType; ! /** Allocation data for this class and method. */ private AllocTypeMethodData typeMethod; /** Allocation data for this method and thread. */ --- 30,37 ---- * @author Jan Stola */ ! public class AllocThreadTypeMethodData extends AllocAbstractStatThreadTypeData { ! /** Allocation data for this type and thread. */ private AllocThreadTypeData threadType; ! /** Allocation data for this type and method. */ private AllocTypeMethodData typeMethod; /** Allocation data for this method and thread. */ *************** *** 39,43 **** /** * MAp of traces of this method in this thread where instances of this class ! * were allocated. Mapping of {@link AllocThreadClassMethodTraceData} objects * and trace IDs. */ --- 39,43 ---- /** * MAp of traces of this method in this thread where instances of this class ! * were allocated. Mapping of {@link AllocThreadTypeMethodTraceData} objects * and trace IDs. */ *************** *** 45,60 **** /** ! * Creates new AllocThreadClassMethodData. * * @param ID unique ID of this object. ! * @param threadClass allocation data for this class and thread. ! * @param classMethod allocation data for this class and method. * @param threadMethod allocation data for this thread and method. */ ! AllocThreadTypeMethodData(int ID, AllocThreadTypeData threadClass, ! AllocTypeMethodData classMethod, AllocThreadMethodData threadMethod) { super(ID); ! this.threadType=threadClass; ! this.typeMethod=classMethod; this.threadMethod=threadMethod; traces=new HashMap(); --- 45,60 ---- /** ! * Creates new AllocThreadTypeMethodData. * * @param ID unique ID of this object. ! * @param threadType allocation data for this type and thread. ! * @param typeMethod allocation data for this type and method. * @param threadMethod allocation data for this thread and method. */ ! AllocThreadTypeMethodData(int ID, AllocThreadTypeData threadType, ! AllocTypeMethodData typeMethod, AllocThreadMethodData threadMethod) { super(ID); ! this.threadType=threadType; ! this.typeMethod=typeMethod; this.threadMethod=threadMethod; traces=new HashMap(); *************** *** 63,76 **** /** ! * Creates new AllocThreadClassMethodData. * * @param sid data returned by communication layer ! * @param threadClass allocation data for this class and thread. ! * @param classMethod allocation data for this class and method. * @param threadMethod allocation data for this thread and method. */ ! AllocThreadTypeMethodData( IProf.sID sid, AllocThreadTypeData threadClass, ! AllocTypeMethodData classMethod, AllocThreadMethodData threadMethod ) { ! this( sid.objId, threadClass, classMethod, threadMethod ); //if (sid.alloc!=null) //do not test this, its an error --- 63,76 ---- /** ! * Creates new AllocThreadTypeMethodData. * * @param sid data returned by communication layer ! * @param threadType allocation data for this type and thread. ! * @param typeMethod allocation data for this type and method. * @param threadMethod allocation data for this thread and method. */ ! AllocThreadTypeMethodData( IProf.sID sid, AllocThreadTypeData threadType, ! AllocTypeMethodData typeMethod, AllocThreadMethodData threadMethod ) { ! this( sid.objId, threadType, typeMethod, threadMethod ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 79,85 **** /** ! * Returns allocation data for this class and thread. * ! * @return allocation data for this class and thread. */ public AllocThreadTypeData getThreadType() { --- 79,85 ---- /** ! * Returns allocation data for this type and thread. * ! * @return allocation data for this type and thread. */ public AllocThreadTypeData getThreadType() { *************** *** 88,94 **** /** ! * Returns allocation data for this class and method. * ! * @return allocation data for this class and method. */ public AllocTypeMethodData getTypeMethod() { --- 88,94 ---- /** ! * Returns allocation data for this type and method. * ! * @return allocation data for this type and method. */ public AllocTypeMethodData getTypeMethod() { *************** *** 107,113 **** /** * Returns map of traces of this method in this thread where instances of this ! * class were allocated. * ! * @return mapping of {@link AllocThreadClassTraceData} objects and trace IDs. */ public Map getTraces() { --- 107,113 ---- /** * Returns map of traces of this method in this thread where instances of this ! * type (class or array of classes) were allocated. * ! * @return mapping of {@link AllocThreadTypeTraceData} objects and trace IDs. */ public Map getTraces() { *************** *** 117,124 **** /** * Adds trace of this method in this thread where instances of this ! * class were allocated. * * @param trace trace of this method in this thread where instances of this ! * class were allocated. */ void addTrace(AllocThreadTypeTraceData trace) { --- 117,124 ---- /** * Adds trace of this method in this thread where instances of this ! * type (class or array of classes) were allocated. * * @param trace trace of this method in this thread where instances of this ! * type were allocated. */ void addTrace(AllocThreadTypeTraceData trace) { *************** *** 143,146 **** --- 143,149 ---- /* * $Log$ + * Revision 1.2 2002/03/01 11:40:12 vachis + * doc changes + * * Revision 1.1 2002/02/15 22:37:30 vachis * code refactorization Class..Data renamed to Type..Data Index: AllocThreadTypeTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocThreadTypeTraceData.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** AllocThreadTypeTraceData.java 15 Feb 2002 22:37:30 -0000 1.1 --- AllocThreadTypeTraceData.java 1 Mar 2002 11:40:12 -0000 1.2 *************** *** 27,34 **** * @author Jan Stola */ ! public class AllocThreadTypeTraceData extends AllocAbstractStatThreadClassData { ! /** Allocation data for this class and trace. */ private AllocTypeTraceData typeTrace; ! /** Allocation data for this class, thread and method. */ private AllocThreadTypeMethodData threadTypeMethod; /** Allocation data for this thread and trace. */ --- 27,34 ---- * @author Jan Stola */ ! public class AllocThreadTypeTraceData extends AllocAbstractStatThreadTypeData { ! /** Allocation data for this type and trace. */ private AllocTypeTraceData typeTrace; ! /** Allocation data for this type, thread and method. */ private AllocThreadTypeMethodData threadTypeMethod; /** Allocation data for this thread and trace. */ *************** *** 36,61 **** /** ! * Creates new AllocThreadClassTraceData. * * @param ID unique ID of this object. ! * @param classTrace allocation data for this class and trace. ! * @param threadClassMethod allocation data for this class, thread and method. * @param threadTrace allocation data for this thread and trace. */ ! AllocThreadTypeTraceData(int ID, AllocTypeTraceData classTrace, ! AllocThreadTypeMethodData threadClassMethod, AllocThreadTraceData threadTrace) { super(ID); ! this.typeTrace=classTrace; ! this.threadTypeMethod=threadClassMethod; this.threadTrace=threadTrace; } /** ! * Creates new AllocThreadClassTraceData. * * @param sid data returned by communication layer ! * @param classTrace allocation data for this class and trace. ! * @param threadClassMethod allocation data for this class, thread and method. * @param threadTrace allocation data for this thread and trace. */ --- 36,61 ---- /** ! * Creates new AllocThreadTypeTraceData. * * @param ID unique ID of this object. ! * @param typeTrace allocation data for this type and trace. ! * @param threadTypeMethod allocation data for this type, thread and method. * @param threadTrace allocation data for this thread and trace. */ ! AllocThreadTypeTraceData(int ID, AllocTypeTraceData typeTrace, ! AllocThreadTypeMethodData threadTypeMethod, AllocThreadTraceData threadTrace) { super(ID); ! this.typeTrace=typeTrace; ! this.threadTypeMethod=threadTypeMethod; this.threadTrace=threadTrace; } /** ! * Creates new AllocThreadTypeTraceData. * * @param sid data returned by communication layer ! * @param typeTrace allocation data for this type and trace. ! * @param threadTypeMethod allocation data for this type, thread and method. * @param threadTrace allocation data for this thread and trace. */ *************** *** 70,76 **** /** ! * Returns allocation data for this class and trace. * ! * @return allocation data for this class and trace. */ public AllocTypeTraceData getTypeTrace() { --- 70,76 ---- /** ! * Returns allocation data for this type and trace. * ! * @return allocation data for this type and trace. */ public AllocTypeTraceData getTypeTrace() { *************** *** 79,85 **** /** ! * Returns allocation data for this class, thread and method. * ! * @return allocation data for this class, thread and method. */ public AllocThreadTypeMethodData getThreadTypeMethod() { --- 79,85 ---- /** ! * Returns allocation data for this type, thread and method. * ! * @return allocation data for this type, thread and method. */ public AllocThreadTypeMethodData getThreadTypeMethod() { *************** *** 100,103 **** --- 100,106 ---- /* * $Log$ + * Revision 1.2 2002/03/01 11:40:12 vachis + * doc changes + * * Revision 1.1 2002/02/15 22:37:30 vachis * code refactorization Class..Data renamed to Type..Data Index: AllocTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocTraceData.java,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -r1.12 -r1.13 *** AllocTraceData.java 16 Feb 2002 12:47:45 -0000 1.12 --- AllocTraceData.java 1 Mar 2002 11:40:12 -0000 1.13 *************** *** 39,44 **** private MethodData method; /** ! * Map of classes whose instances were allocated in this trace. ! * Mapping of {@link AllocClassTraceData} objects and class IDs. */ private Map types; --- 39,44 ---- private MethodData method; /** ! * Map of types (classes or arrays of classes) whose instances were allocated in this trace. ! * Mapping of {@link AllocTypeTraceData} objects and class IDs. */ private Map types; *************** *** 98,104 **** /** ! * Returns map of classes whose instances were allocated in this trace. * ! * @return mapping of {@link AllocClassTraceData} objects and class IDs. */ public Map getTypes() { --- 98,104 ---- /** ! * Returns map of types (classes or arrays of classes) whose instances were allocated in this trace. * ! * @return mapping of {@link AllocTypeTraceData} objects and class IDs. */ public Map getTypes() { *************** *** 107,127 **** /** ! * Adds allocClass whose were allocated in this trace. AllocClass ! * can be instance of class its array. * ! * @param allocClass allocClass that were allocated in this trace. */ ! void addType(AllocTypeTraceData allocClass) { //FIXMEE: ! types.put(new Integer(allocClass.getID()), allocClass); } /** ! * Returns class (with given ID) whose instances were allocated * in this trace. * ! * @param ID ID of the class. ! * @return class (with given ID) whose instances were allocated ! * in this trace or <code>null</code> if such class does not exist. */ public AllocTypeTraceData getType(int ID) { --- 107,127 ---- /** ! * Adds type that was allocated in this trace. Type ! * can be instance of class or its array. * ! * @param allocType allocType that were allocated in this trace. */ ! void addType(AllocTypeTraceData allocType) { //FIXMEE: ! types.put(new Integer(allocType.getID()), allocType); } /** ! * Returns type (with given ID) that instances were allocated * in this trace. * ! * @param ID ID of the type. ! * @return type (with given ID) that instances were allocated ! * in this trace or <code>null</code> if such type does not exist. */ public AllocTypeTraceData getType(int ID) { *************** *** 163,166 **** --- 163,169 ---- /* * $Log$ + * Revision 1.13 2002/03/01 11:40:12 vachis + * doc changes + * * Revision 1.12 2002/02/16 12:47:45 vachis * fix Index: AllocTypeData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocTypeData.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -r1.3 -r1.4 *** AllocTypeData.java 16 Feb 2002 16:21:53 -0000 1.3 --- AllocTypeData.java 1 Mar 2002 11:40:12 -0000 1.4 *************** *** 29,63 **** * @author Jan Stola */ ! public class AllocTypeData extends AllocAbstractStatThreadClassData { ! /** Class to which this allocation data belongs. */ private ClassData clazz; /** ! * Type of the class (for example JVMPI_NORMAL_OBJECT, JVMPI_CLASS, * JVMPI_BOOLEAN etc.) */ private int arrayType; //PENDING /** ! * Map of methods where instance of this class were allocated. ! * Mapping between {@link AllocClassMethodData} objects and method IDs. */ private Map methods; /** ! * Map of threads in which instances of this class were allocated. ! * Mapping between {@link AllocThreadClassData} objects and thread IDs. */ private Map threads; /** ! * Creates new AllocClassData. * * @param ID unique ID of this object. ! * @param classData class to which this allocation data belongs. ! * @param classID object ID of the Class object of this class. ! * @param type type of this class. */ ! AllocTypeData(int ID, ClassData classData, int type) { super(ID); this.clazz=classData; ! this.arrayType=type; methods=new HashMap(); //??use EMPTY_MAP threads= Collections.EMPTY_MAP; --- 29,63 ---- * @author Jan Stola */ ! public class AllocTypeData extends AllocAbstractStatThreadTypeData { ! /** Class related to this type (class or array of classes), may be NULL for arrays of ints,bytes,etc. */ private ClassData clazz; /** ! * Type of array (for example JVMPI_NORMAL_OBJECT, JVMPI_CLASS, * JVMPI_BOOLEAN etc.) */ private int arrayType; //PENDING /** ! * Map of methods where instance of this type (class or array of classes) were allocated. ! * Mapping between {@link AllocTypeMethodData} objects and method IDs. */ private Map methods; /** ! * Map of threads in which instances of this type (class or array of classes) were allocated. ! * Mapping between {@link AllocThreadTypeData} objects and thread IDs. */ private Map threads; /** ! * Creates new AllocTypeData. * * @param ID unique ID of this object. ! * @param classData class related to this type (class or array of classes), may be NULL for arrays of ints,bytes,etc.. ! * @param typeID object ID of the AllocType object. ! * @param arrayType arrayType of this type. */ ! AllocTypeData(int ID, ClassData classData, int arrayType) { super(ID); this.clazz=classData; ! this.arrayType=arrayType; methods=new HashMap(); //??use EMPTY_MAP threads= Collections.EMPTY_MAP; *************** *** 67,71 **** * Creates new AllocClassData. * @param sid data returned by communication layer ! * @param clazz class to which this allocation data belongs. */ AllocTypeData(IProf.sID sid, ClassData clazz) { --- 67,71 ---- * Creates new AllocClassData. * @param sid data returned by communication layer ! * @param clazz class related to this type (class or array of classes), may be NULL for arrays of ints,bytes,etc.. */ AllocTypeData(IProf.sID sid, ClassData clazz) { *************** *** 77,83 **** /** ! * Returns class to which this allocation data belongs. * ! * @return class to which this allocation data belongs. */ public ClassData getClazz() { --- 77,83 ---- /** ! * Returns class related to this type (class or array of classes). * ! * @return class related to this type (class or array of classes), may be NULL for arrays of ints,bytes,etc.. */ public ClassData getClazz() { *************** *** 86,92 **** /** ! * Returns type of the class. * ! * @return type of the class. */ public int getArrayType() { --- 86,92 ---- /** ! * Returns arrayType. * ! * @return arrayType. */ public int getArrayType() { *************** *** 95,101 **** /** ! * Returns map of methods where instance of this class were allocated. * ! * @return mapping between {@link AllocClassMethodData} objects and method IDs. */ public Map getMethods() { --- 95,101 ---- /** ! * Returns map of methods where instance of this type (class or array of classes) were allocated * ! * @return mapping between {@link AllocTypeMethodData} objects and method IDs. */ public Map getMethods() { *************** *** 104,108 **** /** ! * Adds method where instance of this class was allocated. * * @param method method where instance of this class were allocated. --- 104,108 ---- /** ! * Adds method where instance of this type (class or array of classes) was allocated. * * @param method method where instance of this class were allocated. *************** *** 113,120 **** /** ! * Returns method (with given ID) where instance of this class was allocated. * * @param ID ID of the method. ! * @return method (with given ID) where instance of this class was allocated * or <code>null</code> if such method does not exist. */ --- 113,120 ---- /** ! * Returns method (with given ID) where instance of this type (class or array of classes) was allocated. * * @param ID ID of the method. ! * @return method (with given ID) where instance of this type (class or array of classes) was allocated * or <code>null</code> if such method does not exist. */ *************** *** 124,130 **** /** ! * Return map of threads in which instances of this class were allocated. * ! * @return mapping between {@link AllocThreadClassData} objects and thread IDs. */ public Map getThreads() { --- 124,130 ---- /** ! * Return map of threads in which instances of this type (class or array of classes) were allocated. * ! * @return mapping between {@link AllocThreadTypeData} objects and thread IDs. */ public Map getThreads() { *************** *** 133,139 **** /** ! * Adds thread where instances of this class were allocated. * ! * @param thread where instances of this class were allocated. */ void addThread(AllocThreadTypeData thread) { --- 133,139 ---- /** ! * Adds thread where instances of this type (class or array of classes) were allocated. * ! * @param thread where instances of this type (class or array of classes) were allocated. */ void addThread(AllocThreadTypeData thread) { *************** *** 144,152 **** /** ! * Returns thread (with given ID) where instances of this class * were allocated. * * @param ID ID of the thread. ! * @return thread (with given ID) where instances of this class * were allocated or <code>null</code> if such thread does not exist. */ --- 144,152 ---- /** ! * Returns thread (with given ID) where instances of this type (class or array of classes) * were allocated. * * @param ID ID of the thread. ! * @return thread (with given ID) where instances of this type (class or array of classes) * were allocated or <code>null</code> if such thread does not exist. */ *************** *** 159,162 **** --- 159,165 ---- /* * $Log$ + * Revision 1.4 2002/03/01 11:40:12 vachis + * doc changes + * * Revision 1.3 2002/02/16 16:21:53 vachis * code refacorization Class.. to Type... (forgotten methods) Index: AllocTypeMethodData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocTypeMethodData.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** AllocTypeMethodData.java 15 Feb 2002 22:37:30 -0000 1.1 --- AllocTypeMethodData.java 1 Mar 2002 11:40:12 -0000 1.2 *************** *** 30,47 **** * @author Jan Stola */ ! public class AllocTypeMethodData extends AllocAbstractStatThreadClassData { ! /** Allocation data for this class. */ ! private AllocTypeData clazz; /** Allocation data for this method. */ private MethodData method; /** ! * Map of traces of the method in which instances of this class were ! * allocated. Mapping between {@link AllocClassTraceData} objects and * trace IDs. */ private Map traces; /** ! * Map of threads where the method was called and instances of this class ! * allocated. Mapping between {@link AllocThreadClassMethodData} objects * and thread IDs. */ --- 30,48 ---- * @author Jan Stola */ ! public class AllocTypeMethodData extends AllocAbstractStatThreadTypeData { ! /** Allocation data for this type. */ ! private AllocTypeData type; /** Allocation data for this method. */ private MethodData method; /** ! * Map of traces of the method in which instances of this type (class or array of classes) ! * were ! * allocated. Mapping between {@link AllocTypeTraceData} objects and * trace IDs. */ private Map traces; /** ! * Map of threads where the method was called and instances of this type (class or array of classes) ! * were allocated. Mapping between {@link AllocThreadClassMethodData} objects * and thread IDs. */ *************** *** 49,61 **** /** ! * Creates new AllocClassMethodData. * * @param ID unique ID of this object. ! * @param clazz allocation data for this class. * @param method allocation data for this method. */ ! AllocTypeMethodData(int ID, AllocTypeData clazz, MethodData method) { super(ID); ! this.clazz=clazz; this.method=method; traces=new HashMap(); --- 50,62 ---- /** ! * Creates new AllocTypeMethodData. * * @param ID unique ID of this object. ! * @param type allocation data for this type. * @param method allocation data for this method. */ ! AllocTypeMethodData(int ID, AllocTypeData type, MethodData method) { super(ID); ! this.type=type; this.method=method; traces=new HashMap(); *************** *** 64,75 **** /** ! * Creates new AllocClassMethodData. * * @param sid data returned by communication layer * @param method allocation data for this method. ! * @param clazz allocation data for this class. */ ! AllocTypeMethodData( IProf.sID sid, AllocTypeData clazz, MethodData method ) { ! this( sid.objId, clazz, method ); //if (sid.alloc!=null) //do not test this, its an error --- 65,76 ---- /** ! * Creates new AllocTypeMethodData. * * @param sid data returned by communication layer * @param method allocation data for this method. ! * @param type allocation data for this type. */ ! AllocTypeMethodData( IProf.sID sid, AllocTypeData type, MethodData method ) { ! this( sid.objId, type, method ); //if (sid.alloc!=null) //do not test this, its an error *************** *** 78,87 **** /** ! * Returns allocation data for this class. * ! * @return allocation data for this class. */ ! public AllocTypeData getClazz() { ! return clazz; } --- 79,88 ---- /** ! * Returns allocation data for this type. * ! * @return allocation data for this type. */ ! public AllocTypeData getType() { ! return type; } *************** *** 96,103 **** /** ! * Returns map of traces of the method in which instances of this class were * allocated. * ! * @return mapping between {@link AllocClassTraceData} objects and trace IDs. */ public Map getTraces() { --- 97,104 ---- /** ! * Returns map of traces of the method in which instances of this type (class or array of classes) were * allocated. * ! * @return mapping between {@link AllocTypeTraceData} objects and trace IDs. */ public Map getTraces() { *************** *** 106,112 **** /** ! * Adds trace of the method in which instances of this class were allocated. * ! * @param trace trace of the method in which instances of this class were * allocated. */ --- 107,113 ---- /** ! * Adds trace of the method in which instances of this type were allocated. * ! * @param trace trace of the method in which instances of this type (class or array of classes) were * allocated. */ *************** *** 117,125 **** /** * Returns trace (with given ID) of the method in which instances of this ! * class were allocated. * * @param ID ID of the trace. * @return trace (with given ID) of the method in which instances of this ! * class were allocated or <code>null</code> if such trace does not exist. */ public AllocTypeTraceData getTrace(int ID) { --- 118,126 ---- /** * Returns trace (with given ID) of the method in which instances of this ! * type (class or array of classes) were allocated. * * @param ID ID of the trace. * @return trace (with given ID) of the method in which instances of this ! * type were allocated or <code>null</code> if such trace does not exist. */ public AllocTypeTraceData getTrace(int ID) { *************** *** 128,135 **** /** ! * Returns map of threads where the method was called and instances of this * class allocated. * ! * @return mapping of {@link AllocThreadClassMethodData} objects and thread IDs. */ public Map getThreads() { --- 129,136 ---- /** ! * Returns map of threads where the method was called and type (class or array of classes) of this * class allocated. * ! * @return mapping of {@link AllocThreadTypeMethodData} objects and thread IDs. */ public Map getThreads() { *************** *** 138,146 **** /** ! * Adds thread where the method was called and instances of this class * allocated. * * @param thread thread where the method was called and instances of this ! * class allocated. */ void addThread(AllocThreadTypeMethodData thread) { --- 139,147 ---- /** ! * Adds thread where the method was called and instances of this type (class or array of classes) * allocated. * * @param thread thread where the method was called and instances of this ! * type allocated. */ void addThread(AllocThreadTypeMethodData thread) { *************** *** 150,158 **** /** * Returns thread (with given ID) where the method was called and instances ! * of this class allocated. * * @param ID ID of the thread. * @return thread (with given ID) where the method was called and instances ! * of this class allocated or <code>null</code> if such thread does not exist. */ public AllocThreadTypeMethodData getThread(int ID) { --- 151,159 ---- /** * Returns thread (with given ID) where the method was called and instances ! * of this type (class or array of classes) allocated. * * @param ID ID of the thread. * @return thread (with given ID) where the method was called and instances ! * of this type allocated or <code>null</code> if such thread does not exist. */ public AllocThreadTypeMethodData getThread(int ID) { *************** *** 164,167 **** --- 165,171 ---- /* * $Log$ + * Revision 1.2 2002/03/01 11:40:12 vachis + * doc changes + * * Revision 1.1 2002/02/15 22:37:30 vachis * code refactorization Class..Data renamed to Type..Data Index: AllocTypeTraceData.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/data/AllocTypeTraceData.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** AllocTypeTraceData.java 15 Feb 2002 22:37:30 -0000 1.1 --- AllocTypeTraceData.java 1 Mar 2002 11:40:12 -0000 1.2 *************** *** 30,55 **** * @author Jan Stola */ ! public class AllocTypeTraceData extends AllocAbstractStatThreadClassData { ! /** Allocation data for this class and method. */ ! private AllocTypeMethodData classMethod; /** Allocation data for this trace. */ private AllocTraceData trace; /** ! * Map of threads where instances of this class were allocated in given trace. ! * Mapping of {@link AllocThreadClassTraceData} objects and thread IDs. */ private Map threads; /** ! * Creates new AllocClassTraceData. * * @param ID unique ID of this object. ! * @param classMethod allocation data for this class and method. * @param trace allocation data for this trace. */ ! AllocTypeTraceData(int ID, AllocTypeMethodData classMethod, AllocTraceData trace) { super(ID); ! this.classMethod=classMethod; this.trace=trace; threads=new HashMap(); --- 30,55 ---- * @author Jan Stola */ ! public class AllocTypeTraceData extends AllocAbstractStatThreadTypeData { ! /** Allocation data for this type and method. */ ! private AllocTypeMethodData typeMethod; /** Allocation data for this trace. */ private AllocTraceData trace; /** ! * Map of threads where instances of this type (class or array of classes) were allocated in given trace. ! * Mapping of {@link AllocThreadTypeTraceData} objects and thread IDs. */ private Map threads; /** ! * Creates new AllocTypeTraceData. * * @param ID unique ID of this object. ! * @param typeMethod allocation data for this type and method. * @param trace allocation data for this trace. */ ! AllocTypeTraceData(int ID, AllocTypeMethodData typeMethod, AllocTraceData trace) { super(ID); ! this.typeMethod=typeMethod; this.trace=trace; threads=new HashMap(); *************** *** 57,64 **** /** ! * Creates new AllocClassTraceData. * @param sid data returned by communication layer * @param trace allocation data for this trace. ! * @param classMethod allocation data for this class and method. */ AllocTypeTraceData( IProf.sID sid, AllocTypeMethodData classMethod, --- 57,64 ---- /** ! * Creates new AllocTypeTraceData. * @param sid data returned by communication layer * @param trace allocation data for this trace. ! * @param typeMethod allocation data for this type and method. */ AllocTypeTraceData( IProf.sID sid, AllocTypeMethodData classMethod, *************** *** 71,80 **** /** ! * Returns allocation data for this class and method. * ! * @return allocation data for this class and method. */ ! public AllocTypeMethodData getClassMethod() { ! return classMethod; } --- 71,80 ---- /** ! * Returns allocation data for this type (class or array of classes) and method. * ! * @return allocation data for this type and method. */ ! public AllocTypeMethodData getTypeMethod() { ! return typeMethod; } *************** *** 89,96 **** /** ! * Returns map of threads where instances of this class were allocated * in given trace. * ! * @return mapping of {@link AllocThreadClassTraceData} objects and thread IDs. */ public Map getThreads() { --- 89,96 ---- /** ! * Returns map of threads where instances of this type (class or array of classes) * in given trace. * ! * @return mapping of {@link AllocThreadTypeTraceData} objects and thread IDs. */ public Map getThreads() { *************** *** 99,105 **** /** ! * Adds thread where instances of this class were allocated in given trace. * ! * @param thread thread where instances of this class were allocated * in given trace. */ --- 99,105 ---- /** ! * Adds thread where instances of this type (class or array of classes) were allocated in given trace. * ! * @param thread thread where instances of this type were allocated * in given trace. */ *************** *** 109,117 **** /** ! * Returns thread (with given ID) where instances of this class were * allocated in given trace. * * @param ID ID of the thread. ! * @return thread (with given ID) where instances of this class were * allocated in given trace or <code>null</code> if such thread does * not exist. --- 109,117 ---- /** ! * Returns thread (with given ID) where instances of this type (class or array of classes) were * allocated in given trace. * * @param ID ID of the thread. ! * @return thread (with given ID) where instances of this type were * allocated in given trace or <code>null</code> if such thread does * not exist. *************** *** 125,128 **** --- 125,131 ---- /* * $Log$ + * Revision 1.2 2002/03/01 11:40:12 vachis + * doc changes + * * Revision 1.1 2002/02/15 22:37:30 vachis * code refactorization Class..Data renamed to Type..Data |
From: Marek P. <ma...@us...> - 2002-02-28 11:49:31
|
Update of /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/commun In directory usw-pr-cvs1:/tmp/cvs-serv8962/net/sourceforge/javaprofiler/jpiimpl/commun Modified Files: IProf.java Log Message: communication improvements calltree fixes Index: IProf.java =================================================================== RCS file: /cvsroot/javaprofiler/jpiimpl/net/sourceforge/javaprofiler/jpiimpl/commun/IProf.java,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -r1.10 -r1.11 *** IProf.java 31 Jan 2002 12:32:47 -0000 1.10 --- IProf.java 28 Feb 2002 11:49:26 -0000 1.11 *************** *** 2067,2076 **** /** methods called by this method ! ** (list of sCallTree objects) */ public LinkedList children; ! /// number of children public int numOfChildren; }; --- 2067,2082 ---- /** methods called by this method ! ** (list of sCallTree objects, can be null) */ public LinkedList children; ! /// number of children (always zero) public int numOfChildren; + + /// parent method + public sCallTree parent; + + /// number of items in the subtree + public long numOfItems = 1; }; *************** *** 2108,2141 **** } - /** Get subtree of calltree. This method recursively returns - ** the whole calltree - grabs it from binary buffer and stores - ** it as a tree of sCallTree structures. - ** - ** @param b buffer with binary data - ** @param offset position of data in the buffer - ** @param ct output structure - root of the subtree - ** - ** @return position of next item in the buffer */ - - private int getCallTree( Buffer b, int offset, sCallTree ct) { - - offset = getCallTreeItem( b, offset, ct); - - int num = ct.numOfChildren; - - while( num > 0) { - - sCallTree nct = new sCallTree(); - offset = getCallTree( b, offset, nct); - - if( ct.children == null) ct.children = new LinkedList(); - - ct.children.addLast( nct); - num--; - } - - return offset; - } - /** Get calltree. This method returns the whole calltree ** of methods for given thread. --- 2114,2117 ---- *************** *** 2169,2173 **** if( rc != RC_OK) { ! if( rc == RC_BAD_OBJ_ID) throw new BAD_OBJ_ID_Exception(); throw new UNKNOWN_Exception(); --- 2145,2150 ---- if( rc != RC_OK) { ! if( rc == RC_BAD_OBJ_ID) ! throw new BAD_OBJ_ID_Exception(); throw new UNKNOWN_Exception(); *************** *** 2175,2181 **** if( _buf.getSize() == 4) return null; ! ! sCallTree root = new sCallTree(); ! getCallTree( _buf, pos, root); return root; --- 2152,2194 ---- if( _buf.getSize() == 4) return null; ! ! sCallTree parent = null; ! sCallTree root = null; ! ! while( true) { ! ! do { ! ! sCallTree item = new sCallTree(); ! item.parent = parent; ! ! if( parent != null) ! parent.children.addLast( item); ! else root = item; ! ! pos = getCallTreeItem( _buf, pos, item); ! ! parent = item; ! ! if( item.numOfChildren > 0) ! item.children = new LinkedList(); ! ! } while( parent.numOfChildren > 0); ! ! do { ! ! long n = parent.numOfItems; ! parent = parent.parent; ! ! if( parent == null) break; ! ! parent.numOfChildren--; ! parent.numOfItems += n; ! ! } while( parent.numOfChildren == 0); ! ! if( parent == null) break; ! ! } return root; |
From: Marek P. <ma...@us...> - 2002-02-28 11:47:23
|
Update of /cvsroot/javaprofiler/library/src/prof In directory usw-pr-cvs1:/tmp/cvs-serv8382/src/prof Modified Files: prof_method.cpp Log Message: calltree cumulative time Index: prof_method.cpp =================================================================== RCS file: /cvsroot/javaprofiler/library/src/prof/prof_method.cpp,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -r1.8 -r1.9 *** prof_method.cpp 10 Feb 2002 18:36:13 -0000 1.8 --- prof_method.cpp 28 Feb 2002 11:47:19 -0000 1.9 *************** *** 118,121 **** --- 118,123 ---- current->startTime = entryTime; + current->oldCumulativeTime = current->cumulativeTime; + if( p) { *************** *** 123,131 **** p->pureTime += t; ! // while( p) { ! // ! // p->cumulativeTime += t; ! // p = p->parent; ! // } } } --- 125,129 ---- p->pureTime += t; ! p->cumulativeTime += t; } } *************** *** 232,243 **** current->pureTime += t; ! // CallTreeItem* p = current; ! // while( p) { ! // ! // p->cumulativeTime += t; ! // p = p->parent; ! // } ! if( current->parent) current->parent->startTime = exitTime; thread->callTree.current = current->parent; --- 230,240 ---- current->pureTime += t; ! current->cumulativeTime += t; ! ! if( current->parent) { ! current->parent->startTime = exitTime; ! current->parent->cumulativeTime += current->cumulativeTime-current->oldCumulativeTime; ! } thread->callTree.current = current->parent; |
From: Marek P. <ma...@us...> - 2002-02-28 11:03:12
|
Update of /cvsroot/javaprofiler/library In directory usw-pr-cvs1:/tmp/cvs-serv31807 Modified Files: TODO Log Message: Index: TODO =================================================================== RCS file: /cvsroot/javaprofiler/library/TODO,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -r1.6 -r1.7 *** TODO 28 Feb 2002 10:19:13 -0000 1.6 --- TODO 28 Feb 2002 11:03:09 -0000 1.7 *************** *** 0 **** --- 1 ---- + |
From: Marek P. <ma...@us...> - 2002-02-28 10:20:34
|
Update of /cvsroot/javaprofiler/library/src/calltree In directory usw-pr-cvs1:/tmp/cvs-serv21483/src/calltree Modified Files: callTree.cpp callTreeItem.h Log Message: calltree cumulative time Index: callTree.cpp =================================================================== RCS file: /cvsroot/javaprofiler/library/src/calltree/callTree.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** callTree.cpp 10 Feb 2002 18:36:13 -0000 1.2 --- callTree.cpp 28 Feb 2002 10:20:31 -0000 1.3 *************** *** 54,58 **** void CallTree::getBinaryData( Buffer& b) { ! CallTreeItem* p = root; CallTreeItem* q = NULL; --- 54,70 ---- void CallTree::getBinaryData( Buffer& b) { ! CallTreeItem* p = current; ! ! while( p) { ! ! long t = p->cumulativeTime-p->oldCumulativeTime; ! p->oldCumulativeTime = p->cumulativeTime; ! ! if( p->parent) p->parent->cumulativeTime += t; ! ! p = p->parent; ! } ! ! p = root; CallTreeItem* q = NULL; Index: callTreeItem.h =================================================================== RCS file: /cvsroot/javaprofiler/library/src/calltree/callTreeItem.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** callTreeItem.h 31 Jan 2002 12:30:59 -0000 1.1 --- callTreeItem.h 28 Feb 2002 10:20:31 -0000 1.2 *************** *** 58,61 **** --- 58,64 ---- jlong startTime; + /// old cumulative time before a method was entered + jlong oldCumulativeTime; + public: *************** *** 88,91 **** --- 91,95 ---- startTime( 0), + oldCumulativeTime( 0), cumulativeTime( 0), |
From: Marek P. <ma...@us...> - 2002-02-28 10:19:53
|
Update of /cvsroot/javaprofiler/library/demo/06 In directory usw-pr-cvs1:/tmp/cvs-serv21262/demo/06 Modified Files: Test.java Log Message: calltree example Index: Test.java =================================================================== RCS file: /cvsroot/javaprofiler/library/demo/06/Test.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Test.java 31 Jan 2002 12:31:03 -0000 1.1 --- Test.java 28 Feb 2002 10:19:50 -0000 1.2 *************** *** 57,76 **** IProf.THREADS, true); ! IProf.sID sid = (IProf.sID)iterator.next(); ! // ask for more info ! IProf.sThreadInfo sti = (IProf.sThreadInfo)iprof.getInfo( sid.infoId, IProf.THREAD_INFO); ! System.out.println( "thread: " + sti.threadName); ! System.out.println( "info ID: " + sid.infoId); ! System.out.println( "object ID: " + sid.objId); ! // now, ask for calltree of this thread ! IProf.sCallTree ct = iprof.getCallTree( sid.objId); ! if( ct == null) System.out.println( "calltree is empty !"); // now, i don't want anything else, --- 57,85 ---- IProf.THREADS, true); ! while( iterator.hasNext()) { ! IProf.sID sid = (IProf.sID)iterator.next(); ! ! // ask for more info ! IProf.sThreadInfo sti = (IProf.sThreadInfo)iprof.getInfo( sid.infoId, IProf.THREAD_INFO); ! System.out.println( "thread: " +sti.threadName); ! System.out.println( "info ID: " + sid.infoId); ! System.out.println( "object ID: " + sid.objId); ! // now, ask for calltree of this thread ! IProf.sCallTree ct = ! iprof.getCallTree( sid.objId); ! if( ct == null) System.out.println( "calltree is empty !"); + else + System.out.println( "okay, #items = " + + ct.numOfItems); + + System.out.println(); + } // now, i don't want anything else, |
From: Marek P. <ma...@us...> - 2002-02-28 10:19:15
|
Update of /cvsroot/javaprofiler/library In directory usw-pr-cvs1:/tmp/cvs-serv21117 Modified Files: TODO Log Message: Index: TODO =================================================================== RCS file: /cvsroot/javaprofiler/library/TODO,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -r1.5 -r1.6 *** TODO 27 Jan 2002 14:33:24 -0000 1.5 --- TODO 28 Feb 2002 10:19:13 -0000 1.6 *************** *** 1,6 **** - 2002-01-27 - - These features should be implemented in the future: - - * CallTree - both for sampling and exact methods of CPU profiling - --- 0 ---- |
From: Jan S. <st...@us...> - 2002-02-26 01:01:30
|
Update of /cvsroot/javaprofiler/module In directory usw-pr-cvs1:/tmp/cvs-serv12097 Modified Files: javaprofiler.jarContent Log Message: No semantic change. Index: javaprofiler.jarContent =================================================================== RCS file: /cvsroot/javaprofiler/module/javaprofiler.jarContent,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -r1.1.1.1 -r1.2 Binary files /tmp/cvsB9RPkU and /tmp/cvs0RdQxE differ |
From: Jan S. <st...@us...> - 2002-02-26 00:59:54
|
Update of /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/nodes In directory usw-pr-cvs1:/tmp/cvs-serv11441 Modified Files: Bundle.properties Added Files: DataFolderPanel.java DataFolderPanel.form Log Message: Panel for snapshot saving. --- NEW FILE: DataFolderPanel.java --- /* * Sun Public License Notice * * The contents of this file are subject to the Sun Public License Version * 1.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is available at http://www.sun.com/ * * The Original Code is the Java Profiler module. * The Initial Developers of the Original Code are Jan Stola, Pavel Vacha, * Michal Pise, Petr Luner, Lukas Petru and Marek Przeczek. * Portions created by Jan Stola are Copyright (C) 2000-2001. All Rights Reserved. * Portions created by Pavel Vacha are Copyright (C) 2000-2001. All Rights Reserved. * Portions created by Michal Pise are Copyright (C) 2000-2001. All Rights Reserved. * Portions created by Petr Luner are Copyright (C) 2000-2001. All Rights Reserved. * Portions created by Lukas Petru are Copyright (C) 2000-2001. All Rights Reserved. * Portions created by Marek Przeczek are Copyright (C) 2000-2001. All Rights Reserved. * * Contributors: Jan Stola, Pavel Vacha, Michal Pise, Petr Luner, * Lukas Petru and Marek Przeczek. */ package net.sourceforge.javaprofiler.module.nodes; import java.awt.event.KeyEvent; import java.io.IOException; import java.lang.ref.*; import java.util.StringTokenizer; import java.util.ResourceBundle; import java.beans.*; import java.util.Enumeration; import java.text.MessageFormat; import javax.swing.tree.TreeSelectionModel; import javax.swing.tree.TreePath; import javax.swing.tree.DefaultTreeSelectionModel; import javax.swing.event.DocumentEvent; import javax.swing.event.DocumentListener; import javax.swing.event.ChangeListener; import javax.swing.event.ChangeEvent; import javax.swing.ListSelectionModel; import javax.swing.JButton; import javax.swing.KeyStroke; import javax.swing.SwingUtilities; import org.openide.TopManager; import org.openide.DialogDescriptor; import org.openide.WizardDescriptor; import org.openide.loaders.*; import org.openide.nodes.*; import org.openide.explorer.view.*; import org.openide.explorer.ExplorerManager; import org.openide.explorer.propertysheet.editors.EnhancedCustomPropertyEditor; import org.openide.filesystems.*; import org.openide.util.UserCancelException; import org.openide.util.HelpCtx; import org.openide.util.Mutex; import org.openide.util.Utilities; import org.openide.util.NbBundle; import org.openide.util.enum.*; import org.openide.windows.TopComponent; /** * A panel for selecting an existing data folder. */ public class DataFolderPanel extends TopComponent implements DocumentListener, DataFilter, EnhancedCustomPropertyEditor, PropertyChangeListener, VetoableChangeListener { /** Resource bundle for this class. */ private static final ResourceBundle bundle=NbBundle.getBundle(DataFolderPanel.class); /** Prefered dimmension of the panels. */ static java.awt.Dimension PREF_DIM = new java.awt.Dimension(450, 250); /** Format to for default package. */ private static MessageFormat defaultPackageName; /** System reference (FileSystem). */ private Reference system = new WeakReference(null); /** Root node. */ private Node rootNode; /** Last <code>DataFolder</code> object that can be returned. */ private DataFolder df; /** * Creates new form DataFolderPanel */ public DataFolderPanel() { initComponents(); setBorder(new javax.swing.border.EmptyBorder(new java.awt.Insets(8, 8, 8, 8))); rootNode=createPackagesNode(); packagesPanel.getExplorerManager().setRootContext(rootNode); packagesPanel.getExplorerManager().addPropertyChangeListener(this); packagesPanel.getExplorerManager().addVetoableChangeListener(this); // registers itself to listen to changes in the content of document packageName.getDocument().addDocumentListener(this); packageName.unregisterKeyboardAction(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, 0)); } /** * Returns preffered size. */ public java.awt.Dimension getPreferredSize() { return PREF_DIM; } /** * Creates node that displays all packages. */ private Node createPackagesNode() { return TopManager.getDefault().getPlaces().nodes().repository(this); } /** * This method is called from within the constructor to * initialize the form. * WARNING: Do NOT modify this code. The content of this method is * always regenerated by the FormEditor. */ private void initComponents() {//GEN-BEGIN:initComponents java.awt.GridBagConstraints gridBagConstraints; packagesPanel = new org.openide.explorer.ExplorerPanel(); beanTreeView = new org.openide.explorer.view.BeanTreeView(); descriptionLabel = new javax.swing.JLabel(); packageLabel = new javax.swing.JLabel(); packageName = new javax.swing.JTextField(); dirLabel = new javax.swing.JLabel(); directoryName = new javax.swing.JTextField(); createButton = new javax.swing.JButton(); jPanel1 = new javax.swing.JPanel(); nameLabel = new javax.swing.JLabel(); nameTextField = new javax.swing.JTextField(); setLayout(new java.awt.BorderLayout()); packagesPanel.setLayout(new java.awt.GridBagLayout()); beanTreeView.setPopupAllowed(false); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 0; gridBagConstraints.gridy = 2; gridBagConstraints.gridwidth = 3; gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; gridBagConstraints.insets = new java.awt.Insets(8, 8, 8, 8); gridBagConstraints.weightx = 1.0; gridBagConstraints.weighty = 1.0; packagesPanel.add(beanTreeView, gridBagConstraints); descriptionLabel.setText(bundle.getString("LAB_TargetLocationDescription")); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 0; gridBagConstraints.gridy = 1; gridBagConstraints.gridwidth = 3; gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; gridBagConstraints.insets = new java.awt.Insets(8, 8, 0, 8); gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST; packagesPanel.add(descriptionLabel, gridBagConstraints); packageLabel.setText(bundle.getString("LAB_package")); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 0; gridBagConstraints.gridy = 3; gridBagConstraints.insets = new java.awt.Insets(0, 8, 0, 8); gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST; packagesPanel.add(packageLabel, gridBagConstraints); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 1; gridBagConstraints.gridy = 3; gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST; gridBagConstraints.weightx = 1.0; packagesPanel.add(packageName, gridBagConstraints); dirLabel.setText(bundle.getString("LAB_directory")); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 0; gridBagConstraints.gridy = 4; gridBagConstraints.insets = new java.awt.Insets(8, 8, 8, 8); gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST; packagesPanel.add(dirLabel, gridBagConstraints); directoryName.setEnabled(false); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 1; gridBagConstraints.gridy = 4; gridBagConstraints.gridwidth = 2; gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; gridBagConstraints.insets = new java.awt.Insets(8, 0, 8, 8); gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST; packagesPanel.add(directoryName, gridBagConstraints); createButton.setText(bundle.getString("CTL_Create")); createButton.setEnabled(false); createButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { createButtonActionPerformed(evt); } }); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 2; gridBagConstraints.gridy = 3; gridBagConstraints.insets = new java.awt.Insets(0, 8, 0, 8); gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST; packagesPanel.add(createButton, gridBagConstraints); jPanel1.setLayout(new java.awt.GridBagLayout()); nameLabel.setText(bundle.getString("LBL_snapshotName")); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.insets = new java.awt.Insets(0, 0, 0, 8); jPanel1.add(nameLabel, gridBagConstraints); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER; gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; gridBagConstraints.weightx = 1.0; jPanel1.add(nameTextField, gridBagConstraints); gridBagConstraints = new java.awt.GridBagConstraints(); gridBagConstraints.gridx = 0; gridBagConstraints.gridy = 0; gridBagConstraints.gridwidth = 3; gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; gridBagConstraints.insets = new java.awt.Insets(0, 8, 0, 8); packagesPanel.add(jPanel1, gridBagConstraints); add(packagesPanel, java.awt.BorderLayout.CENTER); }//GEN-END:initComponents private void createButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_createButtonActionPerformed try { final DataFolder newDf = (DataFolder)getPropertyValue(); updateDirectory(); enableCreateButton(); } catch (IllegalStateException ex) { throw new RuntimeException(ex.getMessage()); } }//GEN-LAST:event_createButtonActionPerformed // Variables declaration - do not modify//GEN-BEGIN:variables private javax.swing.JLabel nameLabel; private javax.swing.JButton createButton; private javax.swing.JLabel packageLabel; private org.openide.explorer.view.BeanTreeView beanTreeView; private javax.swing.JTextField packageName; private javax.swing.JTextField directoryName; private org.openide.explorer.ExplorerPanel packagesPanel; private javax.swing.JLabel dirLabel; private javax.swing.JLabel descriptionLabel; private javax.swing.JPanel jPanel1; private javax.swing.JTextField nameTextField; // End of variables declaration//GEN-END:variables /** * Filter to accept only folders. * * @param obj data object that should be filtered. * @return <code>true</code> if the object should be displayed, * <code>false</code> otherwise */ public boolean acceptDataObject(DataObject obj) { return obj instanceof DataFolder; } /** * Allow only simple selection. */ public void vetoableChange(PropertyChangeEvent ev) throws PropertyVetoException { if (ExplorerManager.PROP_SELECTED_NODES.equals(ev.getPropertyName())) { Node[] arr = (Node[])ev.getNewValue(); if (arr.length > 1) { throw new PropertyVetoException("Only single selection allowed", ev); // NOI18N } } } /** * Changes in selected node in packages. */ public void propertyChange(PropertyChangeEvent ev) { if (ExplorerManager.PROP_SELECTED_NODES.equals(ev.getPropertyName())) { Node[] arr = packagesPanel.getExplorerManager().getSelectedNodes(); if (!isVisible()) { // in the case we are not shown don't update the panel's state return; } if (arr.length==1) { DataFolder df=(DataFolder)arr[0].getCookie(DataFolder.class); if (df!=null) { setTargetFolder(df); enableCreateButton(); return; } } setTargetFolder((DataFolder)null); } } /** * Modification of package name. */ public void changedUpdate(final javax.swing.event.DocumentEvent p1) { if (p1.getDocument()==packageName.getDocument()) { SwingUtilities.invokeLater(new Runnable() { public void run() { String text=packageName.getText(); if (text!=null) { if (isValid()) { setTargetFolder(text); } updateDirectory(); } enableCreateButton(); } }); return; } } public void removeUpdate(final javax.swing.event.DocumentEvent p1) { if (p1.getDocument()==packageName.getDocument()) { SwingUtilities.invokeLater(new Runnable() { public void run() { if (packageName.getText().length()==0) { FileSystem fs=(FileSystem)system.get(); if (fs!=null) { DataFolder df=DataFolder.findFolder(fs.getRoot()); setTargetFolder(df); packageName.selectAll(); } } String text=packageName.getText(); if (text != null) { if (isValid()) { setTargetFolder(text); } updateDirectory(); } enableCreateButton(); } }); } } public void insertUpdate(final javax.swing.event.DocumentEvent p1) { changedUpdate(p1); } /** * Help for this panel. * @return the help or <code>null</code> if no help is supplied */ public org.openide.util.HelpCtx getHelp() { return new HelpCtx(DataFolderPanel.class); } /** * Test whether the panel is finished and it is safe to proceed to the next one. * If the panel is valid, the "Next" (or "Finish") button will be enabled. * @return <code>true</code> if the user has entered satisfactory information */ public boolean isValid() { String text = packageName.getText(); if (text.length() == 0) { Node[] arr = packagesPanel.getExplorerManager().getSelectedNodes(); if (arr.length == 1 && arr[0] == rootNode) { return false; } } if (text.equals(defaultPackageName((FileSystem)system.get()))) { return true; } StringTokenizer tok = new StringTokenizer(text, "."); // NOI18N while (tok.hasMoreElements()) { String pkg = tok.nextToken(); if (!Utilities.isJavaIdentifier(pkg)) { return false; } } return true; } /** * Computes a suggestion for a given prefix and a list of file objects. * * @param node the node to start with * @param pref prefix * @param first [0] is the first node that satisfies the suggestion * @return the longest continuation string for all folders that * starts with prefix */ private static String computeSuggestion(Node node, String pref, Node[] first) { Node[] arr = node.getChildren().getNodes(); String match = null; for (int i = 0; i < arr.length; i++) { String name = arr[i].getName(); if (name.startsWith(pref)) { // ok, has the right prefix if (match==null) { // first match match=name; if (first!=null) { first[0]=arr[i]; } } else { // find common part of the names int indx=pref.length(); int end=Math.min(name.length(), match.length()); while ((indx<end)&&(match.charAt(indx)==name.charAt(indx))) { indx++; } match=match.substring(0, indx); } } } if (match == null || match.length() == pref.length()) { return null; } else { return match.substring(pref.length()); } } /** * Presets a target folder. * * @param f the folder * @return true if succeeded */ boolean setTargetFolder(final DataFolder f) { boolean exact; Node n; String name; boolean defaultPackageNameUsed = false; df = f; if (f!=null) { FileObject fo = f.getPrimaryFile(); name = fo.getPackageName('.'); StringTokenizer st=new StringTokenizer(name, "."); // NOI18N try { FileSystem fs=fo.getFileSystem(); if (fo.isRoot()) { name=""; // NOI18N defaultPackageNameUsed=true; } system = new WeakReference(fs); Enumeration en = new SequenceEnumeration( new SingletonEnumeration(fs.getSystemName()), st ); n = NodeOp.findPath(rootNode, en); exact = true; } catch (FileStateInvalidException ex) { // invalid state of file system => back to root n = rootNode; name = ""; // NOI18N exact = false; } catch (NodeNotFoundException ex) { n = ex.getClosestNode(); DataFolder df = (DataFolder)n.getCookie(DataFolder.class); if (df != null) { name = df.getPrimaryFile().getPackageName('.'); } else { name = ""; // NO-I18N } exact = false; } } else { // null folder => use root n = rootNode; name = null; exact = true; } // remove listener + do change + add listener ExplorerManager em = packagesPanel.getExplorerManager(); em.removePropertyChangeListener(this); packageName.getDocument().removeDocumentListener(this); try { em.setSelectedNodes(new Node[] { n }); } catch (PropertyVetoException ex) { throw new InternalError(); } packageName.setText(name); updateDirectory(); packageName.getDocument().addDocumentListener(this); em.addPropertyChangeListener(this); return exact; } /** * Getter for target folder. If the folder does not * exists it is created at this point. * @param create true if the target folder should be created. * @return the target folder * @exception IOException if the possible creation of the folder fails */ private DataFolder getTargetFolder(boolean create) throws IOException { if (create&&isValid()) { FileSystem fs=(FileSystem)system.get(); if (fs!=null) { DataFolder folder=DataFolder.findFolder(fs.getRoot()); String currentName=packageName.getText(); if (currentName.length()>0) { String f=currentName.replace('.', '/'); folder=DataFolder.create(folder, f); } df=folder; return folder; } } return df; } /** * Presets a target folder. * * @param f the name of target folder * @return true if succeeded */ private boolean setTargetFolder(final String f) { Node n=null; NodeNotFoundException closest=null; // first of all test the currently selected nod // for location of closest java.util.Collection selected=new java.util.HashSet( java.util.Arrays.asList( packagesPanel.getExplorerManager().getSelectedNodes() )); Node[] arr = rootNode.getChildren().getNodes(); for (int i = 0; i < arr.length; i++) { Node root = arr[i]; StringTokenizer st = new StringTokenizer(f, "."); // NOI18N try { n = NodeOp.findPath(root, st); break; } catch (NodeNotFoundException ex) { if (!st.hasMoreElements()) { // a test for !hasMoreElements is here to be sure that // all tokens has been read, so only the last item // has not been found // check whether we can continue from the nod final String sugg = computeSuggestion( ex.getClosestNode(), ex.getMissingChildName(), null ); if (closest==null||selected.contains(root)&&sugg!=null) { // if we can go on and there has been no suggestion o // this is the current filesystem => go o closest = ex; } } } } if (n!=null) { // closest node not used closest=null; } else { if (closest==null) { // the node has not been even found return false; } // we will select the closest node found - old version n=closest.getClosestNode(); } // remove listener + do change + add listener ExplorerManager em=packagesPanel.getExplorerManager(); em.removePropertyChangeListener(this); // change the text if we want to add suggestion if (closest!=null) { Node[] first=new Node[1]; final String sugg=computeSuggestion( closest.getClosestNode(), closest.getMissingChildName(), first ); if (sugg != null) { packageName.getDocument().removeDocumentListener( DataFolderPanel.this ); packageName.setText(f + sugg); updateDirectory(); javax.swing.text.Caret c = packageName.getCaret(); c.setDot(f.length() + sugg.length()); c.moveDot(f.length()); packageName.getDocument().addDocumentListener( DataFolderPanel.this ); } if (first[0] != null) { // show the first node that fits n = first[0]; } } // change the node try { em.setSelectedNodes(new Node[] {n}); //beanTreeView.selectionChanged(new Node[] { n }, em); } catch (PropertyVetoException ex) { throw new InternalError(); } // change the selected filesystem df = (DataFolder)n.getCookie(DataFolder.class); if (df != null) { try { FileSystem fs = df.getPrimaryFile().getFileSystem(); system = new WeakReference(fs); } catch (FileStateInvalidException ex) { } } em.addPropertyChangeListener(this); return closest == null; } /** * Creates default package name for given file system. * * @param fs the file system * @return localized name of default package */ private static String defaultPackageName(FileSystem fs) { if (defaultPackageName == null) { defaultPackageName = new MessageFormat( bundle.getString("FMT_TemplateDefaultPackageName") ); } String n = fs == null ? "" : fs.getDisplayName(); return defaultPackageName.format(new Object[] { n }); } /** * Updates directory name */ private void updateDirectory() { StringBuffer sb = new StringBuffer(); FileSystem fs = (FileSystem)system.get(); if (fs != null) { sb.append(fs.getDisplayName()); } String name = packageName.getText(); if (name.equals(defaultPackageName(fs))) { name = ""; } if (name.length() > 0) { sb.append(java.io.File.separatorChar); sb.append(name.replace('.', java.io.File.separatorChar)); } directoryName.setText(sb.toString()); } /** * Sets the state of the createButton. */ private void enableCreateButton() { String name = null; if (df != null) { name = df.getPrimaryFile().getPackageName('.'); } else { name = ""; } if (name.equals(packageName.getText())) { // nothing to create createButton.setEnabled(false); } else { createButton.setEnabled(isValid()); } } /** * Get the customized property value. * * @return the property value * @exception InvalidStateException when the custom property editor * does not contain a valid property value (and thus it should not be set) */ public Object getPropertyValue() throws IllegalStateException { if (isValid()) { DataFolder old = df; try { df = getTargetFolder(true); return df; } catch (IOException x) { TopManager.getDefault().notifyException(x); throw new IllegalStateException(); } } else { throw new IllegalStateException(); } } /** * Returns name of the snapshot. */ public String getSnapshotName() { return nameTextField.getText(); } } /* * $Log: DataFolderPanel.java,v $ * Revision 1.1 2002/02/26 00:59:51 stolis * Panel for snapshot saving. * */ --- NEW FILE: DataFolderPanel.form --- <?xml version="1.0" encoding="UTF-8" ?> <Form version="1.1"> <SyntheticProperties> <SyntheticProperty name="designerSize" type="java.awt.Dimension" value="-84,-19,0,5,115,114,0,18,106,97,118,97,46,97,119,116,46,68,105,109,101,110,115,105,111,110,65,-114,-39,-41,-84,95,68,20,2,0,2,73,0,6,104,101,105,103,104,116,73,0,5,119,105,100,116,104,120,112,0,0,1,44,0,0,1,-111"/> </SyntheticProperties> <Layout class="org.netbeans.modules.form.compat2.layouts.DesignBorderLayout"/> <SubComponents> <Container class="org.openide.explorer.ExplorerPanel" name="packagesPanel"> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignBorderLayout" value="org.netbeans.modules.form.compat2.layouts.DesignBorderLayout$BorderConstraintsDescription"> <BorderConstraints direction="Center"/> </Constraint> </Constraints> <Layout class="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout"/> <SubComponents> <Container class="org.openide.explorer.view.BeanTreeView" name="beanTreeView"> <Properties> <Property name="popupAllowed" type="boolean" value="false"/> </Properties> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription"> <GridBagConstraints gridX="0" gridY="2" gridWidth="3" gridHeight="1" fill="1" ipadX="0" ipadY="0" insetsTop="8" insetsLeft="8" insetsBottom="8" insetsRight="8" anchor="10" weightX="1.0" weightY="1.0"/> </Constraint> </Constraints> <Layout class="org.netbeans.modules.form.compat2.layouts.support.JScrollPaneSupportLayout"/> </Container> <Component class="javax.swing.JLabel" name="descriptionLabel"> <Properties> <Property name="text" type="java.lang.String" editor="org.netbeans.modules.form.RADConnectionPropertyEditor"> <Connection code="bundle.getString("LAB_TargetLocationDescription")" type="code"/> </Property> </Properties> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription"> <GridBagConstraints gridX="0" gridY="1" gridWidth="3" gridHeight="1" fill="2" ipadX="0" ipadY="0" insetsTop="8" insetsLeft="8" insetsBottom="0" insetsRight="8" anchor="17" weightX="0.0" weightY="0.0"/> </Constraint> </Constraints> </Component> <Component class="javax.swing.JLabel" name="packageLabel"> <Properties> <Property name="text" type="java.lang.String" editor="org.netbeans.modules.form.RADConnectionPropertyEditor"> <Connection code="bundle.getString("LAB_package")" type="code"/> </Property> </Properties> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription"> <GridBagConstraints gridX="0" gridY="3" gridWidth="1" gridHeight="1" fill="0" ipadX="0" ipadY="0" insetsTop="0" insetsLeft="8" insetsBottom="0" insetsRight="8" anchor="18" weightX="0.0" weightY="0.0"/> </Constraint> </Constraints> </Component> <Component class="javax.swing.JTextField" name="packageName"> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription"> <GridBagConstraints gridX="1" gridY="3" gridWidth="1" gridHeight="1" fill="2" ipadX="0" ipadY="0" insetsTop="0" insetsLeft="0" insetsBottom="0" insetsRight="0" anchor="18" weightX="1.0" weightY="0.0"/> </Constraint> </Constraints> </Component> <Component class="javax.swing.JLabel" name="dirLabel"> <Properties> <Property name="text" type="java.lang.String" editor="org.netbeans.modules.form.RADConnectionPropertyEditor"> <Connection code="bundle.getString("LAB_directory")" type="code"/> </Property> </Properties> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription"> <GridBagConstraints gridX="0" gridY="4" gridWidth="1" gridHeight="1" fill="0" ipadX="0" ipadY="0" insetsTop="8" insetsLeft="8" insetsBottom="8" insetsRight="8" anchor="18" weightX="0.0" weightY="0.0"/> </Constraint> </Constraints> </Component> <Component class="javax.swing.JTextField" name="directoryName"> <Properties> <Property name="enabled" type="boolean" value="false"/> </Properties> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription"> <GridBagConstraints gridX="1" gridY="4" gridWidth="2" gridHeight="1" fill="2" ipadX="0" ipadY="0" insetsTop="8" insetsLeft="0" insetsBottom="8" insetsRight="8" anchor="18" weightX="0.0" weightY="0.0"/> </Constraint> </Constraints> </Component> <Component class="javax.swing.JButton" name="createButton"> <Properties> <Property name="text" type="java.lang.String" editor="org.netbeans.modules.form.RADConnectionPropertyEditor"> <Connection code="bundle.getString("CTL_Create")" type="code"/> </Property> <Property name="enabled" type="boolean" value="false"/> </Properties> <Events> <EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="createButtonActionPerformed"/> </Events> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription"> <GridBagConstraints gridX="2" gridY="3" gridWidth="1" gridHeight="1" fill="0" ipadX="0" ipadY="0" insetsTop="0" insetsLeft="8" insetsBottom="0" insetsRight="8" anchor="18" weightX="0.0" weightY="0.0"/> </Constraint> </Constraints> </Component> <Container class="javax.swing.JPanel" name="jPanel1"> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription"> <GridBagConstraints gridX="0" gridY="0" gridWidth="3" gridHeight="1" fill="2" ipadX="0" ipadY="0" insetsTop="0" insetsLeft="8" insetsBottom="0" insetsRight="8" anchor="10" weightX="0.0" weightY="0.0"/> </Constraint> </Constraints> <Layout class="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout"/> <SubComponents> <Component class="javax.swing.JLabel" name="nameLabel"> <Properties> <Property name="text" type="java.lang.String" editor="org.netbeans.modules.form.RADConnectionPropertyEditor"> <Connection code="bundle.getString("LBL_snapshotName")" type="code"/> </Property> </Properties> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription"> <GridBagConstraints gridX="-1" gridY="-1" gridWidth="1" gridHeight="1" fill="0" ipadX="0" ipadY="0" insetsTop="0" insetsLeft="0" insetsBottom="0" insetsRight="8" anchor="10" weightX="0.0" weightY="0.0"/> </Constraint> </Constraints> </Component> <Component class="javax.swing.JTextField" name="nameTextField"> <Constraints> <Constraint layoutClass="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout" value="org.netbeans.modules.form.compat2.layouts.DesignGridBagLayout$GridBagConstraintsDescription"> <GridBagConstraints gridX="-1" gridY="-1" gridWidth="0" gridHeight="1" fill="2" ipadX="0" ipadY="0" insetsTop="0" insetsLeft="0" insetsBottom="0" insetsRight="0" anchor="10" weightX="1.0" weightY="0.0"/> </Constraint> </Constraints> </Component> </SubComponents> </Container> </SubComponents> </Container> </SubComponents> </Form> Index: Bundle.properties =================================================================== RCS file: /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/nodes/Bundle.properties,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** Bundle.properties 27 Jan 2002 23:13:48 -0000 1.2 --- Bundle.properties 26 Feb 2002 00:59:51 -0000 1.3 *************** *** 40,41 **** --- 40,67 ---- LBL_snapshotTime=Time + + LBL_totalMemory=Total Memory + + LBL_takenMemory=Taken Memory + + LBL_freeMemory=Free Memory + + HINT_freeMemory=Memory in the VM not consumed by the process. + + HINT_totalMemory=Size of the allocated memory by the VM. + + HINT_takenMemory=Memory taken by the process. + + LAB_TargetLocationDescription=Please select a destination for the snapshot + + LAB_directory=Directory + + CTL_Create=Create + + LBL_saveSnapshotDialog=Save snapshot + + LBL_lblSnapshotName=Name: + + LAB_package=Package + + FMT_TemplateDefaultPackageName=<default package> [{0}] |
From: Jan S. <st...@us...> - 2002-02-26 00:58:52
|
Update of /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/nodes In directory usw-pr-cvs1:/tmp/cvs-serv11149 Modified Files: SnapshotNode.java Log Message: Properties time, name, total/taken/free memory added. Actions close and save implemented. Index: SnapshotNode.java =================================================================== RCS file: /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/nodes/SnapshotNode.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** SnapshotNode.java 27 Jan 2002 23:07:54 -0000 1.1 --- SnapshotNode.java 26 Feb 2002 00:58:49 -0000 1.2 *************** *** 21,29 **** package net.sourceforge.javaprofiler.module.nodes; import java.util.*; ! import org.openide.TopManager; import org.openide.actions.*; import org.openide.nodes.*; import org.openide.util.HelpCtx; import org.openide.util.NbBundle; --- 21,37 ---- package net.sourceforge.javaprofiler.module.nodes; + import java.io.*; + import java.awt.*; + import java.awt.event.ActionEvent; + import java.awt.event.ActionListener; import java.util.*; + import javax.swing.*; + import javax.swing.border.TitledBorder; ! import org.openide.*; import org.openide.actions.*; import org.openide.nodes.*; + import org.openide.filesystems.*; + import org.openide.loaders.DataFolder; import org.openide.util.HelpCtx; import org.openide.util.NbBundle; *************** *** 46,51 **** super(Children.LEAF); this.snapshot=snapshot; ! setIconBase("/net/sourceforge/javaprofiler/module/resources/SnapshotNodeIcon"); ! //setDefaultAction(SystemAction.get(?.class)); setDisplayName(snapshot.getName()); setShortDescription(NbBundle.getMessage(SnapshotNode.class, "HINT_snapshotNode")); --- 54,58 ---- super(Children.LEAF); this.snapshot=snapshot; ! setIconBase("/net/sourceforge/javaprofiler/module/resources/SnapshotNodeIcon"); setDisplayName(snapshot.getName()); setShortDescription(NbBundle.getMessage(SnapshotNode.class, "HINT_snapshotNode")); *************** *** 54,58 **** protected SystemAction[] createActions() { ! return new SystemAction[] { SystemAction.get(PropertiesAction.class) }; --- 61,68 ---- protected SystemAction[] createActions() { ! return new SystemAction[] { ! SystemAction.get(CloseSnapshotAction.class), ! SystemAction.get(SaveSnapshotAction.class), ! null, SystemAction.get(PropertiesAction.class) }; *************** *** 70,96 **** sheet.put(props); } ! props.put(new PropertySupport.ReadOnly("name", String.class, bundle.getString("LBL_snapshotName"), bundle.getString("HINT_snapshotName")) { public Object getValue() { return snapshot.getName(); } }); ! props.put(new PropertySupport.ReadOnly("time", String.class, bundle.getString("LBL_snapshotTime"), bundle.getString("HINT_snapshotTime")) { public Object getValue() { return new Long(snapshot.getSnapshot().time()); } }); return sheet; } ! public boolean canCopy() { return false; } } /* * $Log$ * Revision 1.1 2002/01/27 23:07:54 stolis * Node for snapshot. --- 80,169 ---- sheet.put(props); } ! props.put(new PropertySupport.ReadWrite("name", String.class, bundle.getString("LBL_snapshotName"), bundle.getString("HINT_snapshotName")) { public Object getValue() { return snapshot.getName(); } + public void setValue(Object o) { + snapshot.setName((String)o); + SnapshotNode.this.setDisplayName(snapshot.getName()); + } }); ! props.put(new PropertySupport.ReadOnly("time", long.class, bundle.getString("LBL_snapshotTime"), bundle.getString("HINT_snapshotTime")) { public Object getValue() { return new Long(snapshot.getSnapshot().time()); } + }); + props.put(new PropertySupport.ReadOnly("totalMemory", long.class, + bundle.getString("LBL_totalMemory"), bundle.getString("HINT_totalMemory")) { + public Object getValue() { + return new Long(snapshot.getSnapshot().totalMemory()); + } + }); + props.put(new PropertySupport.ReadOnly("freeMemory", long.class, + bundle.getString("LBL_freeMemory"), bundle.getString("HINT_freeMemory")) { + public Object getValue() { + return new Long(snapshot.getSnapshot().freeMemory()); + } + }); + props.put(new PropertySupport.ReadOnly("takenMemory", long.class, + bundle.getString("LBL_takenMemory"), bundle.getString("HINT_takenMemory")) { + public Object getValue() { + return new Long(snapshot.getSnapshot().totalMemory()-snapshot.getSnapshot().freeMemory()); + } }); return sheet; } ! public boolean canCopy() { return false; } + /** + * Closes the snapshot. + */ + public boolean close() { + ProfilerData.getData().removeSnapshot(snapshot); + return true; + } + + /** + * Saves the snapshot. + */ + public void save() { + final DataFolderPanel dfp=new DataFolderPanel(); + DialogDescriptor dd=new DialogDescriptor(dfp, bundle.getString("LBL_saveSnapshotDialog"), true, new ActionListener() { + public void actionPerformed(ActionEvent evt) { + ObjectOutputStream oos=null; + try { + DataFolder df=(DataFolder)dfp.getPropertyValue(); + FileObject pf=df.getPrimaryFile(); + FileObject fo=pf.createData(dfp.getSnapshotName(), "snapshot"); //NOI18N + FileLock fl=fo.lock(); + OutputStream os=fo.getOutputStream(fl); + oos=new ObjectOutputStream(os); + oos.writeObject(snapshot.getSnapshot()); + } catch (Exception e) { + TopManager.getDefault().notifyException(e); + } finally { + try { + if (oos!=null) oos.close(); + } catch (IOException ioe) {} + } + } + }); + Dialog dialog=TopManager.getDefault().createDialog(dd); + dialog.setVisible(true); + } + } /* * $Log$ + * Revision 1.2 2002/02/26 00:58:49 stolis + * Properties time, name, total/taken/free memory added. + * Actions close and save implemented. + * * Revision 1.1 2002/01/27 23:07:54 stolis * Node for snapshot. |
From: Jan S. <st...@us...> - 2002-02-26 00:56:28
|
Update of /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/nodes In directory usw-pr-cvs1:/tmp/cvs-serv10292 Modified Files: SessionNode.java Log Message: Refactoring of create snapshot action. Index: SessionNode.java =================================================================== RCS file: /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/nodes/SessionNode.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** SessionNode.java 27 Jan 2002 23:10:55 -0000 1.2 --- SessionNode.java 26 Feb 2002 00:56:24 -0000 1.3 *************** *** 47,51 **** super(Children.LEAF); this.session=session; ! setIconBase("/net/sourceforge/javaprofiler/module/resources/SessionsNodeIcon"); setDefaultAction(SystemAction.get(MakeCurrentSessionAction.class)); setDisplayName(session.getName()); --- 47,51 ---- super(Children.LEAF); this.session=session; ! setIconBase("/net/sourceforge/javaprofiler/module/resources/SessionNodeIcon"); setDefaultAction(SystemAction.get(MakeCurrentSessionAction.class)); setDisplayName(session.getName()); *************** *** 142,147 **** */ public void createSnapshot() { ! Snapshot snapshot=session.getVM().createSnapshot(); ! ProfilerData.getData().addSnapshot(new net.sourceforge.javaprofiler.module.data.Snapshot(snapshot)); } --- 142,146 ---- */ public void createSnapshot() { ! session.createSnapshot(); } *************** *** 157,160 **** --- 156,162 ---- /* * $Log$ + * Revision 1.3 2002/02/26 00:56:24 stolis + * Refactoring of create snapshot action. + * * Revision 1.2 2002/01/27 23:10:55 stolis * GC, enableGC, disableGC, createSnapshot actions added. |
From: Jan S. <st...@us...> - 2002-02-26 00:54:28
|
Update of /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/nodes In directory usw-pr-cvs1:/tmp/cvs-serv9775 Modified Files: SessionsNode.java Log Message: CanCopy method should return false for this node. Index: SessionsNode.java =================================================================== RCS file: /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/nodes/SessionsNode.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** SessionsNode.java 27 Jan 2002 23:12:18 -0000 1.2 --- SessionsNode.java 26 Feb 2002 00:54:26 -0000 1.3 *************** *** 62,65 **** --- 62,69 ---- return (SessionsChildren)getChildren(); } + + public boolean canCopy() { + return false; + } /** *************** *** 93,96 **** --- 97,103 ---- /* * $Log$ + * Revision 1.3 2002/02/26 00:54:26 stolis + * CanCopy method should return false for this node. + * * Revision 1.2 2002/01/27 23:12:18 stolis * Children updated to keep track of snapshots, too. |
From: Jan S. <st...@us...> - 2002-02-26 00:53:14
|
Update of /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/nodes In directory usw-pr-cvs1:/tmp/cvs-serv9449 Modified Files: SessionKiller.java Log Message: Snapshot on exit created according to the property snapshot_on_exit. Index: SessionKiller.java =================================================================== RCS file: /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/nodes/SessionKiller.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** SessionKiller.java 27 Jan 2002 23:09:09 -0000 1.1 --- SessionKiller.java 26 Feb 2002 00:53:11 -0000 1.2 *************** *** 23,27 **** --- 23,31 ---- import java.util.*; + import org.openide.options.SystemOption; + + import net.sourceforge.javaprofiler.jpi.Snapshot; import net.sourceforge.javaprofiler.jpi.VMDisconnectedException; + import net.sourceforge.javaprofiler.module.ProfilerSettings; import net.sourceforge.javaprofiler.module.data.Session; import net.sourceforge.javaprofiler.module.data.ProfilerData; *************** *** 44,50 **** Session session; while (iter.hasNext()) { ! session=(Session)iter.next(); try { if (session.getVM().isShutdowned()) { session.getVM().shutdown(); ProfilerData.getData().removeSession(session); --- 48,59 ---- Session session; while (iter.hasNext()) { ! session=(Session)iter.next(); try { if (session.getVM().isShutdowned()) { + // create snapshot + ProfilerSettings ps=(ProfilerSettings)SystemOption.findObject(ProfilerSettings.class); + if (ps.getSnapshotOnExit()) { + session.createSnapshot(); + } session.getVM().shutdown(); ProfilerData.getData().removeSession(session); *************** *** 66,69 **** --- 75,81 ---- /* * $Log$ + * Revision 1.2 2002/02/26 00:53:11 stolis + * Snapshot on exit created according to the property snapshot_on_exit. + * * Revision 1.1 2002/01/27 23:09:09 stolis * Thread that removes disconnected/shutdowned sessions from memory. |
From: Jan S. <st...@us...> - 2002-02-26 00:51:25
|
Update of /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/data In directory usw-pr-cvs1:/tmp/cvs-serv8877 Modified Files: ProfilerData.java Log Message: RefreshSessions method made public. Index: ProfilerData.java =================================================================== RCS file: /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/data/ProfilerData.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -r1.2 -r1.3 *** ProfilerData.java 27 Jan 2002 23:04:31 -0000 1.2 --- ProfilerData.java 26 Feb 2002 00:51:21 -0000 1.3 *************** *** 131,135 **** * Refreshes session and snapshot nodes. */ ! private void refreshSessions() { Node profiler=TopManager.getDefault().getPlaces().nodes().environment().getChildren().findChild("profiler"); SessionsNode.SessionsChildren sessionsNode=(SessionsNode.SessionsChildren)profiler.getChildren().findChild("sessions").getChildren(); --- 131,135 ---- * Refreshes session and snapshot nodes. */ ! public void refreshSessions() { Node profiler=TopManager.getDefault().getPlaces().nodes().environment().getChildren().findChild("profiler"); SessionsNode.SessionsChildren sessionsNode=(SessionsNode.SessionsChildren)profiler.getChildren().findChild("sessions").getChildren(); *************** *** 170,173 **** --- 170,176 ---- /* * $Log$ + * Revision 1.3 2002/02/26 00:51:21 stolis + * RefreshSessions method made public. + * * Revision 1.2 2002/01/27 23:04:31 stolis * References to snapshots added. |
From: Jan S. <st...@us...> - 2002-02-26 00:50:13
|
Update of /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/data In directory usw-pr-cvs1:/tmp/cvs-serv8453 Modified Files: Snapshot.java Log Message: Added name property. Index: Snapshot.java =================================================================== RCS file: /cvsroot/javaprofiler/module/net/sourceforge/javaprofiler/module/data/Snapshot.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -r1.1 -r1.2 *** Snapshot.java 27 Jan 2002 23:05:58 -0000 1.1 --- Snapshot.java 26 Feb 2002 00:50:07 -0000 1.2 *************** *** 36,40 **** * @param snapshot snapshot of some profiled process. */ ! public Snapshot(net.sourceforge.javaprofiler.jpi.Snapshot vm) { this.snapshot=snapshot; } --- 36,40 ---- * @param snapshot snapshot of some profiled process. */ ! public Snapshot(net.sourceforge.javaprofiler.jpi.Snapshot snapshot) { this.snapshot=snapshot; } *************** *** 57,64 **** --- 57,78 ---- return snapshot.getName(); } + + /** + * Sets name of this snapshot. + * + * @param name new name of this snapshot. + */ + public void setName(String name) { + String old=getName(); + snapshot.setName(name); + } + } /* * $Log$ + * Revision 1.2 2002/02/26 00:50:07 stolis + * Added name property. + * * Revision 1.1 2002/01/27 23:05:58 stolis * Wrapper for snapshot. |