Final Review Sheet
Use the two previous review sheets for checklists on material
covered prior to tests 1 and 2. Final exam is cumulative.
Below is a checklist for new material since Test 2.
Lambda expression basics
- Know what a lambda expression represents (anonymous method)
- Understand the basics of lambda expression syntax, including shortcuts
- Know where lambdas are typically used (i.e. in function parameters whose types are functional interfaces
- Be able to write a lambda expression to use where a functional interface implementation is expected (as in a paramter list)
Multithreading
- Know the basic concepts of processes and multitasking
- Know the difference between running processes concurrently and
threading (running threads concurrently)
- Understand the advantages of concurrent processing with threads over
doing it with different processes
- Understand the basic thread states
- new
- runnable
- waiting
- timed waiting (sleeping)
- terminated (or dead)
- Know the two basic ways to set up tasks to run concurently:
- Extend class Thread and override run()
- Implement the Runnable interface
- Understand that the second of these requires that the Runnables be
executed on seperately created threads -- and that methods from
java.util.concurrent can help manage this
- Executor interface (and method execute())
- thread pools (understand the Executors methods
newCachedThreadPool() and newFixedThreadPool(), and
the difference between them)
- Understand synchronization -- why and when it's needed
- Understand mutual exclusion and locks
- keyword synchronized and built-in monitors for objects
- includes Object class methods wait(),
notify()
- Alternate technique (since JDK 1.5.0)
- interface java.util.concurrent.locks.Lock
- Condition variables, interface Condition
- await()
- signal()
- signalAll()
- Deadlock
Networking
General Concepts
- client/server model
- Connection-oriented vs. connectionless
- TCP (Transmission Control Protocol) vs. UDP (User Datagram
Protocol)
- Know what a socket is
Java implementations
- package java.net
- Know how to create a URL object
- Know the basics of opening a web page from an applet or
application
- JEditorPane can be used from an application -- can handle
basic HTML
- Understand the process that a client and server must use to set up
connection-oriented sockets
- class ServerSocket -- for listening for connections
- class Socket -- for opening client sockets (connecting to
the server)
- Understand the basics of creating and using datagram oriented sockets
- class DatagramSocket -- for creating the sockets
- class DatagramPacket -- for building packets to send over
datagram sockets
Regular Expressions
- Know the basic rules for building regular expressions, including:
- literal characters
- character classes (includes negations, ranges, unions and
intersections)
- predefined character classes ( . \d \D \s \S \w \W )
- the basic quantifiers (greedy): ( ? * + {n} {n,} {n,m}
)
- putting a ? after a quantifier makes it "reluctant"
- logical operators (and, or, grouping)
- Word and line boundaries ( \b \B ^ $ )
- Be able to take a regular expression and decide whether it matches a
particular string
- Be able to write a basic regular expression using the basic rules
above
- Understand the String class methods that use regular
expressions:
- matches(), replaceAll(), replaceFirst(),
split()