Assignments
- Required: Java style guide: all submitted code should conform.
IntelliJ in CSIL; click for details
- IntelliJ is installed in CSIL labs (Windows OS; Surrey and Burnaby).
- Suggested lab: SRYE 4013 (new building); but other SRYE labs likely OK too.
- Run by pressing Windows key, and then "IntelliJ".
- If IntelliJ asks for a license, point it to this server:
http://cs-sc-licensing.cs.surrey.sfu.ca:8023/
Assignment 1: Game tracker
- Assignment description.
- Sample output.
- CORRECTION: Updated the errorHandling.txt file to fix a typo. Previously said a weight of "03" was invalid. Should be "0.3":
Enter the game weight: 0.3 ERROR: The game weight must be between 1.0 and 5.0
- CORRECTION: Updated the errorHandling.txt file to fix a typo. Previously said a weight of "03" was invalid. Should be "0.3":
- Marking guide.
- Sample output.
- Code style guide which must be followed.
- Due Sept 17th by 11:59pm.
- Solutions folder.
Assignment 2
- Assignment description
- Marking guide
- Useful Resources
- Sample input JSON file, and sample output files
- GSON: Sample Puppy project that can save to JSON and read from JSON.
- GSON: Use in IntelliJ
- GSON: Array or List as Root of JSON file; more info here
- GSON: Reading/Writing LocalDate; more info here or here.
- Due Oct 1st
- Solutions folder.
Assignment 3
- Assignment description
- Sample output
- Marking guide
- Assignment requires you to use a few streams, I suggest first doing the streams exercise listed on the notes page.
- May be one in pairs or individually; due Oct 22nd by 11:59pm
- Solutions folder.
Assignment 4
- Assignment 4 Assignment description.
- Part 1: Shapes
- Part 2: REST API
- You may use the posted solution to Assignment 3 if desired. You may modify this in any way.
- REST API specification
- Web client: download the file and extract so you have a
/public
folder in the root of your Spring Boot project. Then run your program and browse tohttp://localhost:8080/
. - REST API Data Transfer Objects (DTO): Classes which, when serialized, contain the information the web client needs. Edit these and implement static factor methods to create the objects correctly. You can rename the package. These are to be temporary objects; do not save them; that's what your model's for.
- Postman queries to exercise back-end REST API
- Videos
- Video of maze web client
- Video on getting started with Spring Boot in IntelliJ. [Updated 2023]
- Video on creating a REST API with Spring Boot in IntelliJ.
- Using Postman to test a REST API.
- Assignment due (all at once) on Tuesday, November 12th by 11:59pm.
Assignment 5
- Assignment description
- Marking guide
- REST API
- REST API documentation
- Postman queries to exercise back-end REST API.
- Use collection's variables tab to set IDs for your system
- Screenshots of Postman queries (your IDs will be different!)
- curl commands script
- API data transfer object (DTO) classes which the provided web front-end will work with.
Tip: If your model exposes the necessary objects with fields (or getters) named the same way as these classes then you may be able to just skip using these entirely. However, they may be useful to ensure you are sending the correct info to the front-end.
- Files and Resources
- Input data files (.csv)
- Web UI (extract into project root, as in Assignment 4)
- Demo video of using Web UI
- SFU Term Codes
For semester XYZA:
Year = 1900 + 100*X + 10*Y + 1*Z;
Semester (A) = {1=Spring, 4=Summer, 7=Fall}
Ex: Term code 1147 = 2014 Fall
- Due Dec 2nd.
- Submit via CourSys
- See assignment submission directions for how to create/test ZIP file. No JAR file required.
Policies
- Assignment Late Policy
Assignments may be turned in up to 3 days late with 0% penalty. Later than this is 100% penalty (60 minute grace period). Contact the instructor if there are extenuating circumstances. - Extensions and Deferrals
Email Dr. Brian with your request. You may need to complete and email SFU Academic Concession Self-Declaration Form. Doctor's notes are usually not required. - Academic Honesty
- The MOSS tool will be used to check the originality of all electronic submissions.
- SFU's Academic Honesty policy is crucial to earning credit in this course. Violations of the policy will be taken seriously and reported to the department and university.
- Explanation of penalties applied for academic dishonesty.
- AI Policy
- Students may use AI tools (such as GitHub's Copilot, or ChatGPT) to support their programming.
- You must do the high-level design yourself and be able to write all submitted code on your own (even if you used help from the AI).
- You should use the AI to code no more than a few lines at a time: do not have it write all lines of code.
- You must add a comment to any functions that you used the AI's help to write more than 5 line of code.
- Code written exclusively by, or with the help of an AI system is still governed by the academic honesty policies of the course and university. If a significant number of lines of code, or detailed/critical code is found not to be the student's work, then that work will get a zero. If the copied code was not cited correctly (from either a human or AI source) then it will be considered a case of academic dishonesty and the entire assignment may get a grade of 0 and a report on file with the university.
- Note that AI tools are not available during exams, and exams make up the bulk of the percentage for the course.