13 * |
13 * |
14 * Description: Definitions for the class IMemoryActivityModel |
14 * Description: Definitions for the class IMemoryActivityModel |
15 * |
15 * |
16 */ |
16 */ |
17 package com.nokia.s60tools.analyzetool.engine; |
17 package com.nokia.s60tools.analyzetool.engine; |
|
18 |
18 import java.util.AbstractList; |
19 import java.util.AbstractList; |
19 |
20 |
20 import com.nokia.s60tools.analyzetool.engine.statistic.ProcessInfo; |
21 import com.nokia.s60tools.analyzetool.engine.statistic.ProcessInfo; |
21 |
|
22 |
22 |
23 /** |
23 /** |
24 * Interface for the memory model of AnalyzeTool |
24 * Interface for the memory model of AnalyzeTool |
25 */ |
25 */ |
26 public interface IMemoryActivityModel { |
26 public interface IMemoryActivityModel { |
27 |
27 |
28 /** |
28 /** |
29 * Sets the data to use. This will cause listeners to be notified. |
29 * Sets the data to use. This will cause listeners to be notified. |
30 * @param processes The list of processes to set |
30 * |
|
31 * @param processes |
|
32 * The list of processes to set |
31 */ |
33 */ |
32 public void addProcesses(AbstractList<ProcessInfo> processes); |
34 public void addProcesses(AbstractList<ProcessInfo> processes); |
33 |
35 |
34 /** |
36 /** |
35 * Sets the selected ProcessInfo |
37 * Sets the selected ProcessInfo |
|
38 * |
36 * @param processInfo |
39 * @param processInfo |
37 */ |
40 */ |
38 public void setSelectedProcess(ProcessInfo processInfo); |
41 public void setSelectedProcess(ProcessInfo processInfo); |
39 |
42 |
40 /** |
43 /** |
41 * returns the last selected process |
44 * returns the last selected process |
|
45 * |
42 * @return Selected process |
46 * @return Selected process |
43 */ |
47 */ |
44 public ProcessInfo getSelectedProcess(); |
48 public ProcessInfo getSelectedProcess(); |
45 |
49 |
46 /** |
50 /** |
47 * Get the start time of the process that started first |
51 * Get the start time of the process that started first |
|
52 * |
48 * @return time |
53 * @return time |
49 */ |
54 */ |
50 public Long getFirstProcessTime(); |
55 public Long getFirstProcessTime(); |
51 |
56 |
52 /** |
57 /** |
53 * Get end time of the process that ended last |
58 * Get end time of the process that ended last |
|
59 * |
54 * @return Last process time |
60 * @return Last process time |
55 */ |
61 */ |
56 public Long getLastProcessTime(); |
62 public Long getLastProcessTime(); |
57 |
63 |
58 /** |
64 /** |
59 * Get time of the first memory operation |
65 * Get time of the first memory operation |
|
66 * |
60 * @return First memory operation time. |
67 * @return First memory operation time. |
61 */ |
68 */ |
62 public Long getFirstMemOpTime(); |
69 public Long getFirstMemOpTime(); |
63 |
70 |
64 /** |
71 /** |
65 * Get last memory operation time from all processes |
72 * Get last memory operation time from all processes |
|
73 * |
66 * @return Last memory operation time. |
74 * @return Last memory operation time. |
67 */ |
75 */ |
68 public Long getLastMemOpTime(); |
76 public Long getLastMemOpTime(); |
69 |
77 |
70 /** |
78 /** |
71 * get highest cumulated memory |
79 * get highest cumulated memory |
|
80 * |
72 * @return size |
81 * @return size |
73 */ |
82 */ |
74 public int getHighestCumulatedMemoryAlloc(); |
83 public int getHighestCumulatedMemoryAlloc(); |
75 |
84 |
76 /** |
85 /** |
77 * Get list of processes |
86 * Get list of processes |
|
87 * |
78 * @return processes list |
88 * @return processes list |
79 */ |
89 */ |
80 public AbstractList<ProcessInfo> getProcesses(); |
90 public AbstractList<ProcessInfo> getProcesses(); |
81 |
91 |
82 |
|
83 /** |
92 /** |
84 * @param listener the listener to register |
93 * @param listener |
|
94 * the listener to register |
85 */ |
95 */ |
86 void addListener(IMemoryActivityModelChangeListener listener); |
96 void addListener(IMemoryActivityModelChangeListener listener); |
87 |
97 |
88 /** |
98 /** |
89 * @param listener the listener to remove |
99 * @param listener |
|
100 * the listener to remove |
90 */ |
101 */ |
91 void removeListener(IMemoryActivityModelChangeListener listener); |
102 void removeListener(IMemoryActivityModelChangeListener listener); |
92 |
103 |
93 /** |
104 /** |
94 * Returns true if callstack reading from files is done on demand after the |
105 * Returns true if callstack reading from files is done on demand after the |
95 * initial parsing phase. This assumes file positions are available from |
106 * initial parsing phase. This assumes file positions are available from |
96 * BaseInfo |
107 * BaseInfo |
|
108 * |
97 * @return true for deferred callstack reading, false otherwise |
109 * @return true for deferred callstack reading, false otherwise |
98 */ |
110 */ |
99 public boolean isDeferredCallstackReading(); |
111 public boolean isDeferredCallstackReading(); |
100 |
112 |
101 /** |
113 /** |
102 * Indicates whether this model is reading callstacks on demand |
114 * Indicates whether this model is reading callstacks on demand after the |
103 * after the initial parsing phase has finished |
115 * initial parsing phase has finished |
|
116 * |
104 * @param value |
117 * @param value |
105 */ |
118 */ |
106 public void setDeferredCallstackReading(boolean value); |
119 public void setDeferredCallstackReading(boolean value); |
107 |
120 |
108 /** |
121 /** |
109 * Setter for the ICallstackManager |
122 * Setter for the ICallstackManager |
110 * @param callstackManager the CallstackManager to set |
123 * |
|
124 * @param callstackManager |
|
125 * the CallstackManager to set |
111 */ |
126 */ |
112 public void setCallstackManager(ICallstackManager callstackManager); |
127 public void setCallstackManager(ICallstackManager callstackManager); |
113 |
128 |
114 /** |
129 /** |
115 * Getter for ICallstackManager. |
130 * Getter for ICallstackManager. |
|
131 * |
116 * @return CallstackManager |
132 * @return CallstackManager |
117 */ |
133 */ |
118 public ICallstackManager getCallstackManager(); |
134 public ICallstackManager getCallstackManager(); |
119 |
|
120 } |
135 } |