ViRALiC
ViRALiC

Reputation: 1549

Interactive console in Eclipse

I've seen a few posts about this, but very few that provide an accurate answer.

In short, my brothers is just learning the smaller subtleties of Java, and I recommended him start off with Eclipse as, though a little intimidating at first, I find that it is the most flexible tool.

The problem is, that his professor (who said he may use any editor he wanted, FYI), told him to do some simple math by typing it into the console window.

The problem, is of course that the console isn't interactive in Eclipse.

Is there any plugin or magic that can enable such an interactive console for him? Personally, I've never needed it, but he's in a situation where he does, and I told him I'd consult the experts.

NOTE: Forgive the slightly technical question. I will gladly take it elsewhere if this is not the place to ask, but I couldn't think of any place better for a question about Eclipse.

Upvotes: 0

Views: 2879

Answers (3)

Edgardo Genini
Edgardo Genini

Reputation: 663

You can create a "terminal" window to open jshell.

once created the terminal window can be opened from window - show view - terminal.

Create terminal

Terminal running

Upvotes: 1

TheRealFawby
TheRealFawby

Reputation: 112

I'm not aware of this functionality within Eclipse , but I believe this satisfies your need : http://www.javarepl.com/console.html

Upvotes: 1

Derek Baum
Derek Baum

Reputation: 665

You could use an Eclipse scrapbook page:

Create using "File / New / Other / Java / Java Run/Debug / Scrapbook Page"

Then write some code, select it and right-click Execute to run it.

This is not as interactive as javarepl, but it is native to Eclipse.

Upvotes: 4

Related Questions