CS5015: O.-o. Soft. Dev.

Old Announcements.

Note: you may need to refresh your browser to see the latest updates.

Datestamp: 25/3/14

As announced in lectures, there will be a CS5008 (Internet Computing) tutorial on Thursday at 11:00 in G.26. This will include an overview of the exam.

~
The notes for the Review/Exam Overview are online, along with a textbook reading guide (in the Lecture Slides section).

Datestamp: 21/3/14

Lectures next week will be on Java Platform (notes in Lecture Slides page) [Mon and Tue] and an overview of the exam [Wed].

Updated: 20/3/14
Marks for CA4 are online. Sample solutions to follow shortlyonline.

~
[Java] As you may be aware, Java 8 was officially released this week. See what's new in Java 8.

Updated: 19/3/14
The lab sheet for tomorrow, 20th March, is now online. This is on Java GUIs. No submission is required.

~
Note that Chapter 10 Section 4 on Creating Drawings in not covered in the slides. I've uploaded this section here.
~
Compass How To 10.1 goes through drawing a flag (Italian flag but it looks like the Irish one online) step by step. Binoculars Worked Example 10.1 looks at coding a bar chart. This is only available online.

Updated: 18/3/14:
The due date for CA5 has been extended to Friday, 21st March at 10:00pm. CA5 is the last continuous assessment.

~
Note that there is a lab this week on Thursday, 20th at 11:00am.
~
In the textbook, but not the slides you will find Compass Special Topic 10.2 (Local Inner Classess) and Compass Special Topic 10.3 (Anonymous Inner Classess).
~
I've put links to the slides for Deitel, Java: How to Program's chapters on Java GUIs in the Lecture Slides page. This has a more comprehensive treatment of Swing GUIs in Java.
~
I've uploaded the code for the Investment example (with a reset button). This is a modification of InvestmentFrame2 from the textbook.

Datestamp: 11/3/14

~
Compass Special Topic 7.5 (Automatic Resource Management) demonstrates a nice new syntax in Java 7 that can remove the need for a finally clause -- the try-with-resources. See also the Java tutorial.

Updated: 10/2/14
Thursday (13th March) will be a 2-hour lab (11am-1pm). CA5 will be posted online tomorrow, Tue, 11th March. The due date is Wed, 19th March.

~
Marks for CA2 and CA3 are online. Note that you need to use the key emailed to you to read the table. I've posted notes listing common errors for each of these also.
~
A sample solution to CA2 is online. A sample solution to CA3 will follow shortly.
~
The textbook doesn't go into exception handling in detail (although it's sufficient for this course). For a more thorough treatment see Chapter 11 of Deitel (linked from Lecture Slides page). The wikipedia article has a good general overview of exception handling.

Datestamp: 6/3/14

Chapter 7 of the textbook has Compass How To 7.1 (Processing Text Files) which shows you how to develop a text I/O application step-by-step. In addition, Binoculars Worked Example 7.1, online only has a file-based application for analyzing baby names. Video Example 7.1 (Computing a Document's Readability) and Video Example 7.2 (Detecting Accounting Fraud) are online here.

~
I've put the text for Compass Special Topic 7.1 (Reading Web Pages) and Compass Special Topic 7.2 (File Dialog Boxes) online here and here for convenience. Note that I skipped Compass Special Topic 7.3 (Reading and Writing Binary Data).
~
Compass Special Topic 7.4 is a brief note on Regular Expressions. More on Regular Expressions in Java can be found online e.g. in Oracle tutorial lesson.
~
I spotted a typo in Chapter 7, Syntax 7.2 (Catching Exceptions). The argument in the last println such read except.getMessage().
~
I also found a typo in the slides for Chapter 7, slide 28. The last line of code should be: double price = Double.parseDouble(priceString);

Updated:
Thursday (6th Mar) will be a 1-hour tutorial (11am-12pm). The tutorial notes are already online. Since this is 5 pages please read in advance of the tutorial.

~
Reminder: Third assessment is due Friday, 7th March.
~
For added confidentialy, for future marks that I post I will use a set of randomly assigned private keys. I will email out these 3 letter keys to individual students. You should not share your key.

Datestamp: 28/2/14

[Java] A new version of Java SE has been released ( JavaSE 7 update 51). If you are running Java on a laptop you should upgrade and uninstall older insecure versions (unless you have a good reason for running an older version of Java). The changes are mostly security changes such as updates of the Java Control Panel Security tab behaviour (slider and exception site list), signed JARs recommendations and bug fixes -- see release notes.

Updated:
I've put the example we developed in today's lecture/tutorial online here. This is called QuestionDemo4 and is a further development of QuestionDemo3 from Chapter 9 of the book. Specifically, I added new 2-arg constructors to Question and its subclass. I also added implementations of toString to each class. And put in @Override annotations where appropriate. Sample questions are hard-coded in QuestionDemo3.java itself.

~
[Advanced] Information on @Override: See here and API description
~
I spotted an error in the Java code for How To 9.1. The condition (input == "Q") in AccountDemo (end of Step 8.) should be (input.equals("Q")), otherwise the program will never exist. Try it!
~
Note that I'm skipping Compass Special Topic 9.7 (Inheritance and the equals Method) and Compass Special Topic 9.9 (Function Objects)

Updated: 25/2/14:
Thursday (27th Feb) will be a 2-hour lab session (11am-1pm). CA4 is already online.

~
Reminder: Third assessment is due on Wednesday, 26th Feb.
~
Chapter 9 of the textbook has How To 9.1 Compass on developing an inheritance hierarchy (BankAccount example) and Worked Example 9.1 (on-line only) Binoculars on implementing an employee class hierarchy.

Datestamp: 19/2/14

You may have noticed that there are videos (screencasts) as part of the online resources. The videos for Chapter 8 are here. Note that Horstmann uses the BlueJ environment in these videos.

~
Lectures next week on JFE Chapter 9 (Inheritance and Interfaces).
~
I've added a note on common issues myself or Harsh came across correcting CA1s -- see Lab Works page, under results.

Updated: 18/2/14:
[Advanced] I mentioned name mangling in yesterday's lecture (17/2). If you are interested see here. And to glimpse the gory details of what exactly the JVM does see Section 4.3 of JVM spec here.

~
[Advanced] FYI Initialization Blocks see here and here

Updated: 17/2/14:
I've made small changes to CA3 (relating to the maximum count). See the amendments (in blue).

~
Referred to in today's lecture (17/2), Chapter 8 of the textbook has How To 8.1 Compass on implementing a class (ATM Menu example) and the Worked Example 8.1 (on-line only) Binoculars on implementing a bank account class.
~
[Advanced] Section 8.9.5 of Java for Everyone (and slide 40 of Chap 8 slide set) gives a stateful Fish, implementated using static final variables. It is mentioned that this could instead have been implemented using an enum (enumerated type). Indeed it can, but not as straightforward as I first thought. Here is my enum version.
~
And the API for Fish and Fish.Hunger is here

Updated: 15/2/14:
Marks for CA1 are in the Lab Work section. Sample answers and notes on common errors and omissions to follow shortly. If you submitted work that hasn't been corrected please re-submit the file (forward from Send Mail email folder preferably).

Updated: 14/2/14:
Next Thursday (20th Feb) will be a 2-hour lab session (11am-1pm). CA3 is already online.

~
Reminder: Second assessment is due on Wednesday, 19th Feb.

Datestamp: 8/2/14

Next Thursday will be a 1-hour tutorial instead of a lab session (11am-12).

~
The due date for the second assessment is extended. It is now due on Wednesday, 19/2 at close of WGB.
~
Textbook/Slides Update: After Chapter 6 (Arrays and ArrayList) we will skip to Chapter 8 (Objects and Classes). We will go back to Chapter 7 later.
~
If you are looking for more examples, check out Fred Swartz's Java Note, listed in the Web Links section of Website, which has nice short examples.
~
I've expanded the Notes and Tools sections in Web Links.

Datestamp: 4/2/14

Reminder: CA1 is due Wednesday, 5 Feb.

~
The second assessment is now online in the Lab Work section of Webpage. There is a lab on Thursday, 11-1pm.
~
Textbook/Slides Update: Note that I skipped Section 5.9 on Recursion. In Chapter 6 I will skip Special Topic 6.2 (Binary Search), Section 6.6 (Problem Solving) and Section 6.7 (Two-Dimensional Arrays).

Datestamp: 30/1/14

Note that CA1 has been amended with clarifications. Test code is now _not_ required in this assessment. The breakdown of marks is also shown (4 marks per question for total of 20).

Updated: 29/1/14
Not covered in the slides, Chapter 5 of the textbook has a How To Compass on implementing a method (How To 5.1) that is worth a look. Also check out the Worked Examples 5.1 and 5.2 Binoculars online

Datestamp: 28/1/14

The first continuous assessment is online in the Lab Work section. There will be a lab Thursday 11:00am-1pm. The first assessment is due the following Wednesday.

~
CAs are marked out of 20. Note that there will be a penalty (-5) for late submisions. Submissions more than a week late will not be corrected.
~
Note that the Worked Examples 4.1 and 4.2 Binoculars (mentioned in lectures and referred to in textbook) are only available online. Follow this link and browse by chapter or resource.

Datestamp: 21/1/14

The third tutorial is on Thursday 11:00am. The notes are in the Lab Work section of the course Website. The first assessment is next week.

~
One of the only new features in Java 7 a beginner is likely to come across is Strings in switch statements. See here for an example.

Datestamp: 14/1/14

The second tutorial is on Thursday 11:00am. The notes are in the Lab Work section of the course Website.

~
Additional slides for printf() as covered in lectures and applets (optional) are in the Lecture Notes section.

Datestamp: 8/1/14

The first tutorial is on Thursday 11:00am. The notes are in the Lab Work section of the course Website.

~
Java (Oracle JDK) is back on cs1 after cs1 was reinstalled (after a security attack).

Datestamp: 6/1/14

Welcome to CS5015. This course is all about computer programming in Java.

~
The first two sets of lecture slides are on-line. The third lecture and many subsequent lectures will use the slides associated with the textbook.
~
The Web links have been updated for 2014.