Win a copy of TDD for a Shopping Website LiveProject this week in the Testing forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

Equivalence of Eclipse's "Display View" in IntelliJ?

 
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,

In Eclipse, we can open "Display View" to enter some code and execute this code while debugging.
In IntelliJ, how can we do it? I already tried "Evaluating Expressions" but it seems that I can only see values of variables and I cannot enter my customized code (even in "code fragment evaluation" mode).

Thank you very much.
 
Sheriff
Posts: 10445
227
IntelliJ IDE Ubuntu
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I had the IDE open in front of me, so I just tried it in debug mode. Clicked "Evaluate expressions" and then clicked the "Code Fragment mode" button and in the top area editor entered:



and then hit the "Evaluate" button. The output, 7, was shown in the "Result" text area. See screenshot for details.
ide.png
[Thumbnail for ide.png]
Code fragment mode - IntelliJ
 
Swerrgy Smith
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Jaikiran Pai wrote:I had the IDE open in front of me, so I just tried it in debug mode. Clicked "Evaluate expressions" and then clicked the "Code Fragment mode" button and in the top area editor entered:



and then hit the "Evaluate" button. The output, 7, was shown in the "Result" text area. See screenshot for details.



Yes, I know what you mean. However, it seems that we cannot do something more complex as we can do with Eclipse.
For example, I have a Set<String_FullName> named infoSet that have 100000 elements. In "Display View" of eclipse, at one break point I can enter some code to verify whether this set contains the name "Robert" or not. I can insert my code as:



In the "Evaluate expressions" I don't see I can do this.
 
Every snowflake is perfect and unique. And every snowflake contains a very tiny ad.
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic