CIT597 Quiz 2
Fall, 2003 |
Name_________________________________________ |
Please keep all answers short and to the point. Read each question and answer
it; don't add information that wasn't asked for.
- (5 points) What is the default port number for HTTP?
- (5 points) What does the acronym
TCP/IP stand for?
- (5 points) What service does a DNS provide?
- (5 points) What Java package defines Sockets and URLs?
- (4 points) What are the two arguments to the Socket constructor?
- (4 points) In a client, how can you refer to a server running on the same
computer?
- (6 points) What are the three parts of an HTTP request?
- (5 points) What is the difference between
GET and POST
in an HTTP request? (Be sure to indicate which is which.)
- (5 points) What is the purpose of a proxy server?
- (5 points) What keyword is used to prevent different Threads from simultaneously
accessing the same object?
| -- Quiz continues on reverse
side -- |
- (5 points) You can call the constructor for
PrintWriter with
an additional boolean variable. What does this boolean variable
control?
- (8 points) Briefly, how does the absence of unit tests discourage refactoring?
- (10 points) In JUnit terminology, what is tested by:
- a "unit test"?
- a "test case"?
- (10 points) Name the JUnit methods that:
- create a test fixture
- release resources after performing the tests
- (8 points) If you have defined a
Button b1, write two
ways you could get its Class object.
- (5 points) If
c is a Class object, what is the
return type of c.getInterfaces() ?
- (5 points) If
c is a Class object, what is the
return type of c.getModifiers() ?