1CMSC 131 Spring 2007Bonnie Dorr (adapted from Rance Cleaveland)Lecture Set 1: IntroductionToday’s topics:1.Course information2.Tools needed for this course3.Computer terminology basics1CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)CMSC 131Name: “Object-Oriented Programming I”Instructor: Jan PlaneClass meetingsLecture: 03xx Lecture MWF 2-2:50 in CSIC 211704xx Lecture MWF 3-3:50 in CSIC 2117Lab sections (CSIC 2118)0301: MW 10:00 -10:50 in CSIC 21200302: MW 11:00 - 11:50 in CSIC 21200401: MW 11:00 – 11:50 in CSIC 21070402: MW 12:00 – 12:50 in CSIC 21072CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)Coordination of SectionsFive sections total of CMSC 131two lectures taught by me three lectures taught by Fawzi EmadTen TAs in total for the 5 sectionsAll sections will be closely coordinated:Same lecture material on same daySame projectsSame labsCoordinated examsLab/Discussion/Recitation Sectionsexercises – laptopsquizzesnew material occasionally23CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)What Is This Course?A fast-paced introduction to techniques for writing computer programs! Skill Development in ProgrammingConceptual Understanding of ProgrammingNot really “computer science”There will be quite a bit of work but assumes you are starting at level 0.Keys to successAttend all classes and lab sectionsStart assignments early – and continue until you truly understandGet help early if you are having trouble – 2 instructors & 10 TAsStudy every dayit doesn’t work to cram for these examsask questions as soon as you realize you are confusedCheck announcements on course web-page every day4CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)BookJava™ Software Solutions: Foundations of Program Design (5thedition), by Lewis & LoftusLectures do not follow book closelyBook is very useful as a reference5CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)Course Web-Pagewww.cs.umd.edu/class/fall2007/cmsc131/Check daily!Review:AnnouncementsSyllabusContactScheduleLecture slides - outlines36CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)Study QuestionsAvailable on web-pageLogin: studyPassword: dailyLook at them on evenings before class; they will help you keep up7CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)Course SoftwareEclipseAn IDE (integrated development environment)You will use it for writing Java™ programsAccess to Eclipse (it’s free!)You can install it on your own machine: http://www.cs.umd.edu/eclipseAlso accessible in Workstations at Maryland (WAM) labs around campus: http://www.wam.umd.edu/CVS (Concurrent Versions System)A version-management systemYou will use it for submitting your projectsWe will talk more about this later8CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)Tools for Writing ProgramsThe bad old daysText editor: used to create files of source codeCompiler: generate executables from sourceDebugger: trace programs to locate errorsToday: IDEs (= “integrated development environment”)Text editor / compiler / debugger rolled in oneExamples: Eclipse, Visual Studio, etc.49CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)Basics of Eclipsewww.cs.umd.edu/eclipse/EclipseTutorial/Eclipse is used to:CreateEditCompileRunDebugprograms (for this class, Java programs).10CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)Basics of Eclipse-speakProject: collection of related source filesTo create a program in Eclipse:Create a new projectCreate files in the projectPerspective: framework for viewing and/or manipulating programsImportant perspectives in this class:Java: for creating, running programsDebug: for tracing, removing errors in programsCVS repository: for interacting with assignment-submission system11CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)Eclipse Demo512CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)Class Projects with CVSYou will use Eclipse for Java programming in this courseHow will you:obtain (check-out) files that are supplied to yousave (commit) the files for later workturn in (submit) when you are finishedclass projects?CVS (= Concurrent Versions System)Tool for project-file managementMaintains versions, etc.Allows different sites to work on same project13CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)CVS WorldviewFiles =“repository”ServerFiles(local copies)Client 1Files(local copies)Client 2“checkout”“checkout”“commit”“commit”14CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)CVS in More DetailCVS server maintains current versions of files in project (= “repository”)To access files from another machine (“client”), repository files must be “checked out”Changes to files on client may be “committed” to server, with changed files becoming new version(Once a repository is checked out by a client, subsequent versions may be accessed via “update”)615CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)What’s Needed for CVS?Server machineFor CMSC 131, CS linuxlab machinesUser authenticationFor CMSC 131, student linuxlab accounts16CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)How CMSC Project Submission WorksRepository created for each student linuxlabaccountYou check out repository to start work on projectWhen you “save” changes in Eclipse, “commit”automatically invoked by plug-insYou “submit” when finished using Eclipse (UMD plug-in handles relevant CVS commands)17CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)To Checkout a Project1.Set repository locationChange to “CVS Repository Exploring”perspective in Eclipse (“Window -> Open Perspective” …)Right-click in “CVS Repositories” panel and select “New -> Repository Location…”718CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)Adding a CVS RepositoryCommon to everyoneYour linuxlab usernameYour linuxlab passwordDon’t forget to set this!19CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)To Checkout a Project (cont.)1.Open repository name, then “Head”2.Right-click on project name to save20CMSC 131 Fall 2007Jan Plane (adapted from Bonnie Dorr)821CMSC 131 Fall 2007Jan Plane (adapted from Bonnie
View Full Document