Creating and running a Java program. Eclipse Interactive Development Environment (IDE)  Eclipse is an Interactive Development Environment (IDE) for Java.

Slides:



Advertisements
Similar presentations
Introduction to Eclipse. Start Eclipse Click and then click Eclipse from the menu: Or open a shell and type eclipse after the prompt.
Advertisements

COMPUTER PROGRAMMING I Essential Standard 5.02 Understand Breakpoint, Watch Window, and Try And Catch to Find Errors.
Chapter 3: Editing and Debugging SAS Programs. Some useful tips of using Program Editor Add line number: In the Command Box, type num, enter. Save SAS.
Using Eclipse. Getting Started There are three ways to create a Java project: 1:Select File > New > Project, 2 Select the arrow of the button in the upper.
Lesson One: The Beginning Chapter 2: Processing Learning Processing Daniel Shiffman Presentation by Donald W. Smith Graphics from built-in help reference.
Java Integrated Development Environments: ECLIPSE Part1 Installation.
Fall 2007ACS-1903 BlueJ Ron McFadyen Lab 1: Using BlueJ at UofW The purpose of this lab is to give you some experience with BlueJ. Over the course of the.
Presented by IBM developer Works ibm.com/developerworks/ 2006 January – April © 2006 IBM Corporation. Making the most of The Java Development Tools project.
A Guide to Oracle9i1 Creating an Integrated Database Application Chapter 8.
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
ExitTOC Run & Route Directions 2003 Editing Run and Route Directions Edulog.nt v9.2 Use the buttons to navigate the training package First PagePreviousNextLast.
Eclipse IDE. 2 IDE Overview An IDE is an Interactive Development Environment Different IDEs meet different needs BlueJ and DrJava are designed as teaching.
03 Using Eclipse. 2 IDE Overview An IDE is an Interactive Development Environment Different IDEs meet different needs BlueJ and DrJava are designed as.
Introduction to Eclipse. Overview Eclipse Background Obtaining and Installing Eclipse Creating a Workspaces / Projects Creating Classes Compiling and.
Getting started with Eclipse By Alexander Butyaev.
Chapter 9 Introduction to ActionScript 3.0. Chapter 9 Lessons 1.Understand ActionScript Work with instances of movie clip symbols 3.Use code snippets.
Microsoft Office Illustrated Fundamentals Unit B: Understanding File Management.
1 Chapter One A First Program Using C#. 2 Objectives Learn about programming tasks Learn object-oriented programming concepts Learn about the C# programming.
A First Program Using C#
I Can… Define basic file management and related terms Identify levels of a file system Identify and explain ways to view files in Windows OS Explain the.
Microsoft Office 2013 ®® Managing Your Files. XP Objectives Explore the differences between Windows 7 and Windows 8 Plan the organization of files and.
Working with Numbers in Alice - Converting to integers and to strings - Rounding numbers. - Truncating Numbers Samantha Huerta under the direction of Professor.
Project 3 File, Document, Folder Management, Windows XP Explorer Windows XP Service Pack 2 Edition Comprehensive Concepts and Techniques.
The NetBeans IDE CSIS 3701: Advanced Object Oriented Programming.
Using Eclipse. What is Eclipse? The Eclipse Platform is an open source IDE (Integrated Development Environment), created by IBM for developing Java programs.
Dreamweaver – Dreamweaver Extras Web Design Section 8-4 Part or all of this lesson was adapted from the University of Washington’s “Web Design & Development.
Web Programming: Client/Server Applications Server sends the web pages to the client. –built into Visual Studio for development purposes Client displays.
With Windows 7 Introductory© 2011 Pearson Education, Inc. Publishing as Prentice Hall1 Windows 7 Introductory Chapter 2 Managing Libraries Folders, Files.
LLRP GUI Client User Guide
Drexel University Software Engineering Research Group 1 Eclipse for SE101.
Java Environment CSCI 201L Jeffrey Miller, Ph.D. HTTP :// WWW - SCF. USC. EDU /~ CSCI 201 USC CSCI 201L.
Introduction to Eclipse CSC 216 Lecture 3 Ed Gehringer Using (with permission) slides developed by— Dwight Deugo Nesa Matic
Tutorial 11 Five windows included in the Visual Basic Startup Screen Main Form Toolbox Project Explorer (Project) Properties.
1 NORMA Lab. 7 Generating Reports More Display Options File: NORMA_Lab6.ppt. Author: T. Halpin. Last updated: 2009 June 9.
Working with the VB IDE. Running a Program u Clicking the”start” tool begins the program u The “break” tool pauses a program in mid-execution u The “end”
Hello World in the Forte IDE An introduction to the Forte IDE (integrated development environment) writing the classic “Hello World” program in Java.
Unit 1: Java and Eclipse The Eclipse Development Environment.
9/2/ CS171 -Math & Computer Science Department at Emory University.
Computing Fundamentals Module Lesson 10 — File Management with Windows Explorer Computer Literacy BASICS.
Using Microsoft Visual Studio 2005 Original by Suma Rao Revised by John G. McMahon ( 9/6/2008 )
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 8 Debugging, Creating Executable Files, and Distributing a Windows Application.
Vocabulary in VB So Far. Assignment: Used to change the value of an object at run time Used to change the value of an object at run time.
SilkTest 2008 R2 SP1: Silk4J Introduction. ConfidentialCopyright © 2008 Borland Software Corporation. 2 What is Silk4J? Silk4J enables you to create functional.
DELETING TEMPORARY FILES 1.Click “Start” -> “Search” -> “All Files and Folder”. 2.In “All or Part of the file name” box enter “*.tmp” and click “Search”.
CMPF124: Basics Skills for Knowledge Workers Manipulating Windows GUI.
1 Setting Up for RePast, and Running a Repast Stand Alone Example 06/21/2004 by Deddy Koesrindartoto Department of Economics Iowa State University.
Tool Install How to download & install Java 6 & Eclipse updated version based on Dr. G. L. Ray’s slides.
Introduction to Eclipse Programming with an Integrated Development Environment.
Photoshop Actions Lights, Camera, Actions in Photoshop.
Building the CarryDrop simulation in Eclipse Creating a new project with existing code from John Murphy’s RePast tutorial.
XP New Perspectives on Microsoft Windows XP Tutorial 2 1 Microsoft Windows XP Working with Files Tutorial 2.
File and File Systems Compiled by IITG Team Need to be reorganized and reworded.
You’ll Make a spreadsheet which will be like a Mad Libs Game. These Are The Directions.
1 1 1 Introduction to Java. 2 History of Java Java – Originally for intelligent consumer-electronic devices – Then used for creating Web pages with dynamic.
Today Javadoc. Packages and static import. Viewing API source code. Upcoming Topics: –protected access modifier –Using the debugger in Eclipse –JUnit testing.
Chapter 2: The Visual Studio.NET Development Environment Visual Basic.NET Programming: From Problem Analysis to Program Design.
Java IDE Dwight Deugo Nesa Matic
CS 201 Lecture 1 (b) Using an IDE Tarik Booker CS 201: Introduction to Programming California State University, Los Angeles.
Author: Loh Jianxiong Christopher Contributions: Chua Jie Sheng, Li Mengran, Peh Shao Hong, Oo Theong Siang, Tong Chun Kit, Tania Chattopadhyay.
Windows 7 and file management
ATS Application Programming: Java Programming
Eclipse Navigation & Usage.
An Introduction to Computers and Visual Basic
Using Visual Studio with C#
Some Tips for Using Eclipse
Install Ruby If you are running on Mac OS X, Ruby is preinstalled.
How to Run a Java Program
An Introduction to Computers and Visual Basic
Java IDE Dwight Deugo Nesa Matic Portions of the notes for this lecture include excerpts from.
Microsoft Office Illustrated Fundamentals
Presentation transcript:

Creating and running a Java program

Eclipse Interactive Development Environment (IDE)  Eclipse is an Interactive Development Environment (IDE) for Java programmers  It provides project manager  A project manager to manage all Java projects throughout the semester codeeditor NotePad++)  An code editor that helps write correct Java instructions (no need for NotePad++) executionenvironmentcompile testrunwithoutleaving no more Command Line  An execution environment in which one can compile, test, and run Java programs without leaving Eclipse (no more Command Line use)

Eclipse Workspace Eclipse Workspace folder allJavaprojects  An Eclipse Workspace is simply a folder where all Java projects for the semester will be stored must remember where it is  You must remember where it is once you select it write access permissions  It must be a place where you have write access permissions  It must be a place that you can access when you need it thumb driveZ:\ portableharddrive cloudstorageDropBoxOneDriveBox  Example: thumb drive, Z:\ drive, portable hard drive, or cloud storage such as DropBox, OneDrive, Box, etc. Workspace  Make sure there is enough space in the Workspace to hold all projects for the semester

Eclipse Be sure Java is selected Java editor – type code here Error messages and running program output display here Java projects in your workspace

Create a New Java Project Create new Java Project File/New/Java Project

Create New Project – Give it a name Name the project

New Project in the Package Explorer new project PackageExplorer Eclipse  After creating a new project as on the previous slide, it will appear in the Package Explorer column on the left in Eclipse Project name Subfolder for.java files Java library – contains Java API classes such as String, Scanner, etc.

Add a class to the project Right-click on src. Select New/Class New project is open

Adding a new Driver Class Give the class a name If this is the driver class, add a main method Make sure this is checked Click Finish Assign a package name

Generated code Fill in class purpose Fill in method description Fill in body of main method

Add Another Non-Driver class  Use same technique without a main method Class name hw1

Add desired attributes

Generate Default Constructor Select me Deselect All to Generate Default Constructor Select both

Default Constructor Fill in the Description Fill in the body of the default constructor

Generate Parameterized Constructor  Follow the same process but do NOT deselect the attributes (fields)  All of the following code is generated

Resulting code so far... Fill in purpose Fill in parameter details

Generate Getters and Setters Select me Choose those you want Remember it is not always desirable to have getters and setters – depends on what needs to remain private

Added Getters/Setters Depending on which are selected in the previous dialog, a series of getters and setters like this is generated

Other code generators Comment out (or uncomment) the selected lines of code Add a block of comments to a method you have written Generate a toString method for your class Generate hashCode ( ) and equals ( ) methods

Renaming an attribute or method  Use Refactor / Rename to change the name of a method or attribute of a class, a local variable, parameter, or even the name of a class.  This changes the name everywhere it appears in the code.

If you refer to a class that is not in your own project or in any imported class, Eclipse puts a red squiggly line underneath the reference Which import do I need?

Let Eclipse help you select the right import  Hover the mouse cursor over the underlined word and a tool-tip will appear; choose what you want from the tool-tip and Eclipse does rest Click this choice

Alternatively, do this  Press ctrl-shift-O (letter O, not zero) and Eclipse will fill in the correct import for you or it will list possible imports and let you choose one

Running a program To run a program Right-click on (or in) the driver (code)

Another way to run the program … Click me

… from your workspace Submitting a project

Project Folder Contents in Workspace Contains.java files for your project Contains the compiled.class files

The bin folder This folder contains the compiled.class files. Do NOT submit them.

The src Folder.java files for the project Zip ONLY these files, naming the zipped folder appropriately. DO NOT zip the containing folder (src or DemoProject1) If you are using a non-Windows machine such as a Mac or a Linux machine, it is your responsibility to be sure your system does NOT add extraneous folders and other items to your zipped folder.

Zipping the files Use Send To Compressed Folder or … … some other archiving tool such as 7-zip Select the files to be zipped and right-click