Important: As noted in the General Information handout, we will not be accepting late submissions for assignment 7, even if you have late days.



Your last assignment will give you practice with Classes and collections. You will also learn how to write a program that interacts with the internet.



This assignment may (optionally) be done in pairs. As a reminder, you may only pair up with others with the same section time and location.

Assignment Files



Frequently asked questions and errata


FAQ: Since parts of this assignment are new (previously there was no over-internet communication) there may be questions or issues that come up. We will keep a list of them here.

  • Question: Previous assignments were due at 10:30am, is this one really due at 5pm?
    Answer: Yes. Consider it a 6 hour extension.
  • Question: Why does the comment for FacePamphletProfile's getFriends() method say we should return an iterator when the return type is a list?
    Answer: The comment was incorrect; we have corrected it to clarify that this method should return a list of that profile's friends.
  • Question: Every time I try to run the server, I get a "ClassNotFound" exception. Help?
    Answer: This happens mostly to Section Leaders. Some old versions of Eclipse are set to compile to Java 6 (even though you most likely have the most up to date version of Java on your computer). I use features from Java 7 in the new library. You need to change Eclipse. Go to Eclipse -> Preferences, and under Java -> Compiler, set the target Java version to something more modern.
  • Question: Every time I try to run the server, I get an "UnsupportedClassVersionError". Help?
    Answer: This happens in rare instances when for some reason Eclipse is not configured to use the latest version of Java that you have installed. To fix this, go to Eclipse -> Preferences, and under Java select "Installed JREs". Click the "Search" button in the toolbar on the right, and then make sure "Java SE 8" is the installed JRE that has a checkmark next to it. Then click "OK" and restart Eclipse.
  • Question: On Windows, the provided client program doesn't seem to work when setting profile pictures. Help?
    Answer: This is a known bug that has been fixed in the latest version of the client JAR in the starter code. Please redownload it and see if that fixes the problem.
  • Question: What does it mean if one of the ServerTester tests fails with an "Unexpected end of file from server" error?
    Answer: This usually happens when the server crashes when sending a response. Check Eclipse for crash messages and see if you can figure out what the issue is.
  • Question: I'm on a Mac and can't run the client JAR file from Eclipse - it gives me an error message. What should I do?
    Answer: macOS's security restrictions sometimes prevent you from running software from unidentified developers (but you can trust us :) ). To get around this, find the JAR file on your computer (wherever you downloaded the starter code to), right click on the file, and click "Open".

Have a question not covered here? Send me an email.