问题
Is there a way in Idea to dump the content of a large - very - array of ints into the clipboard ?
'copy value' on an array return nothing.
回答1:
To get the value in the clipboard using copy value, you need to define a "Java Data Type Renderer" to interpret the content of your array.
- Right click on your array variable
- Select "View as->Create..."
- In the "Java Data Type Renderers" window, create a new entry, set "When rendering a node, use following expression" with
Arrays.toString(this)
. - Apply, select your array variable and do
Ctrl-C
to get the content.
回答2:
- Right click variable
- Evaluate expression
- Type
*nameOfYourArray*.toString()
- Click evaluate
Ctrl-C
to get content
来源:https://stackoverflow.com/questions/33549721/dumping-a-huge-array-in-intellij-idea-debugger