|
1 | 1 | package com.jetbrains.python.debugger.pydev; |
2 | 2 |
|
3 | | -import com.google.common.base.Function; |
4 | 3 | import com.google.common.collect.Collections2; |
5 | 4 | import com.google.common.collect.Lists; |
6 | 5 | import com.google.common.collect.Maps; |
|
10 | 9 | import consulo.execution.debug.breakpoint.SuspendPolicy; |
11 | 10 | import consulo.execution.debug.frame.XValueChildrenList; |
12 | 11 | import consulo.logging.Logger; |
13 | | - |
14 | 12 | import org.jspecify.annotations.Nullable; |
| 13 | + |
15 | 14 | import java.util.*; |
16 | 15 |
|
17 | 16 | /** |
@@ -163,7 +162,8 @@ public XValueChildrenList loadVariable(String threadId, String frameId, PyDebugV |
163 | 162 | return debugger(threadId).loadVariable(threadId, frameId, var); |
164 | 163 | } |
165 | 164 |
|
166 | | - public ArrayChunk loadArrayItems(String threadId, String frameId, PyDebugValue var, int rowOffset, int colOffset, int rows, int cols, String format) throws PyDebuggerException |
| 165 | + @Override |
| 166 | + public ArrayChunk loadArrayItems(String threadId, String frameId, PyDebugValue var, int rowOffset, int colOffset, int rows, int cols, String format) throws PyDebuggerException |
167 | 167 | { |
168 | 168 | return debugger(threadId).loadArrayItems(threadId, frameId, var, rowOffset, colOffset, rows, cols, format); |
169 | 169 | } |
@@ -250,17 +250,12 @@ public Collection<PyThreadInfo> getThreads() |
250 | 250 | if(!isOtherDebuggersEmpty()) |
251 | 251 | { |
252 | 252 | //here we add process id to thread name in case there are more then one process |
253 | | - return Collections.unmodifiableCollection(Collections2.transform(threads, new Function<PyThreadInfo, PyThreadInfo>() |
254 | | - { |
255 | | - @Override |
256 | | - public PyThreadInfo apply(PyThreadInfo t) |
257 | | - { |
258 | | - String threadName = ThreadRegistry.threadName(t.getName(), t.getId()); |
259 | | - PyThreadInfo newThread = new PyThreadInfo(t.getId(), threadName, t.getFrames(), t.getStopReason(), t.getMessage()); |
260 | | - newThread.updateState(t.getState(), t.getFrames()); |
261 | | - return newThread; |
262 | | - } |
263 | | - })); |
| 253 | + return Collections.unmodifiableCollection(Collections2.transform(threads, t -> { |
| 254 | + String threadName = ThreadRegistry.threadName(t.getName(), t.getId()); |
| 255 | + PyThreadInfo newThread = new PyThreadInfo(t.getId(), threadName, t.getFrames(), t.getStopReason(), t.getMessage()); |
| 256 | + newThread.updateState(t.getState(), t.getFrames()); |
| 257 | + return newThread; |
| 258 | + })); |
264 | 259 | } |
265 | 260 | else |
266 | 261 | { |
@@ -439,7 +434,8 @@ private void addDebugger(RemoteDebugger debugger) |
439 | 434 | } |
440 | 435 | } |
441 | 436 |
|
442 | | - public void addCloseListener(RemoteDebuggerCloseListener listener) |
| 437 | + @Override |
| 438 | + public void addCloseListener(RemoteDebuggerCloseListener listener) |
443 | 439 | { |
444 | 440 | myMainDebugger.addCloseListener(listener); |
445 | 441 | } |
|
0 commit comments