views:

31

answers:

3

Like firebug's console,I can type in the scripts directly.

Is there a similar place in eclipse out there?

Or do I install some plugin to have the feature?

A: 

You can use the Display window to type in code snippets, set variable values and evaluate whilst debugging.

http://help.eclipse.org/help32/index.jsp?topic=/org.eclipse.jdt.doc.user/reference/views/display/ref-display_view.htm

davek
Seems it's diabled in **eclipse pdt** (for `php`)?
A: 

The "watch" view can be used to execute simple snippets of code.

In some circumstances, I use the groovy shell (in a separate window) to check how a code snippet will behave. It isn't practical when complex data structures or library classes are involved, but for a respectable number of cases it works very well.

Tomislav Nakic-Alfirevic
A: 

You can use the Expression and Display views. There's a set of excellent free video tutorials on the Eclipse debugger that you can see here. The aforementioned views are talked about in lesson 3.

JRL