Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Using an Integrated Development Environment. Integrated Development Environments An Integrated Development Environment, or IDE, permits you to edit,

Similar presentations


Presentation on theme: "1 Using an Integrated Development Environment. Integrated Development Environments An Integrated Development Environment, or IDE, permits you to edit,"— Presentation transcript:

1 1 Using an Integrated Development Environment

2 Integrated Development Environments An Integrated Development Environment, or IDE, permits you to edit, compile, test, and debug a program using a single program. There are several IDEs for Java. We will look at one of them, jGRASP, today. 2

3 Objectives You will be able to use the jGRASP IDE to edit, compile, test, and debug Java programs. 3

4 Installing jGRASP jGRASP is available on lab computers. To install it on your own computer, see http://www.csee.usf.edu/~turnerr/Programming_Concepts/ 120_Installing_jGRASP.pdf http://www.csee.usf.edu/~turnerr/Programming_Concepts/ 120_Installing_jGRASP.pdf Versions are available for Windows Mac Linux 4

5 jGRASP Tutorials There is an extensive set of jGRASP tutorials, with links on the start page: 5

6 Using jGRASP 6 Start page. Initial Directory Editing Window Ignore this window for now. Navigation Buttons Directory Window

7 Navigate to Your Test Directory 7 Double click on file name to open file in editing window.

8 Source File Open in Editing Window 8 Click here to maximize editing window.

9 Editing Window 9

10 10 Make a change. Click here to save. Click here to run program.

11 Program Running 11 Console Window

12 12

13 Program Running 13

14 Expand and Refresh Directory Window 14 Here is our output file. Double click file name to display the file.

15 Output File Contents 15

16 Control Structure Diagrams From the Overview tutorial: 16

17 Genrating a Control Structure Diagram 17

18 18

19 If you want to remove the CSD 19

20 Folding a Program Element 20 Double click here to "fold" (collapse) the entire class.

21 21 Double click again to unfold the entire class. Or double click + to unfold layer by layer.

22 Showing Line Numbers 22

23 Line Numbers Shown 23

24 Using the Debugger The debugger permits us to set breakpoints in our source code. One of the most useful features of an IDE. When a running program reaches a breakpoint it will stop (prior to executing the statement). We can examine variables. We can single-step, or continue from the breakpoint. 24

25 Using the Debugger 25 Be sure Debug Mode is enabled in the Build menu.

26 Setting a Breakpoint 26 Click in the gray margin column (inside the edit window) to set a breakpoint.

27 Breakpoint Set 27

28 Start Debugging 28

29 Variables in the Debug Tab 29

30 Continuing from Breakpoint 30 Single Step Resume

31 Another Way to Set a Breakpoint 31 Left click on an executable statement, then right click and select Toggle Breakpoint.

32 Breakpoint Set 32

33 Stopped at Breakpoint 33

34 Program Complete 34

35 Back to Browse Tab 35 Double click on output.txt to open in edit window

36 Output File 36

37 Assignment Reading Go to the jGRASP web site http://www.jgrasp.org/ Read tutorials: Overview (2.0) Getting Started (2.0) CSD (2.0) Debugger Lab Project 12 Cars from Files 37


Download ppt "1 Using an Integrated Development Environment. Integrated Development Environments An Integrated Development Environment, or IDE, permits you to edit,"

Similar presentations


Ads by Google