1. Which of these interface abstractes the output of messages from httpd?
a) LogMessage
b) LogResponse
c) Httpdserver
d) httpdResponse
2. Which of these class is used to create servers that listen for either local or remote client programs?
a) httpServer
b) ServerSockets
c) MimeHeader
d) HttpResponse
3. Which of these is a standard for communicating multimedia content over email?
a) http
b) https
c) Mime
d) httpd
4. Which of these methods is used to make raw MIME formatted string?
a) parse()
b) toString()
c) getString()
d) parseString()
5. Which of these class is used for operating on request from the client to the server?
a) http
b) httpDecoder
c) httpConnection
d) httpd
6. Which of these method of MimeHeader is used to return the string equivalent of the values stores on MimeHeader?
a) string()
b) toString()
c) convertString()
d) getString()
7. What is the output of this program?
Note: Host URL is written in html and simple text.
a) html
b) text
c) html/text
d) text/html
8. Which of these is an instance variable of class httpd?
a) port
b) cache
c) log
d) All of the mentioned
9. Which of these is an instance variable of httpd that is a Hashtable?
a) port
b) cache
c) log
d) stopFlag
10. What is the output of this program?
a) gksquiz
b) gksquiz.blogspot.com
c) www.gksquiz.blogspot.com
d) http://www.gksquiz.blogspot.com/javamcq
a) LogMessage
b) LogResponse
c) Httpdserver
d) httpdResponse
2. Which of these class is used to create servers that listen for either local or remote client programs?
a) httpServer
b) ServerSockets
c) MimeHeader
d) HttpResponse
3. Which of these is a standard for communicating multimedia content over email?
a) http
b) https
c) Mime
d) httpd
4. Which of these methods is used to make raw MIME formatted string?
a) parse()
b) toString()
c) getString()
d) parseString()
5. Which of these class is used for operating on request from the client to the server?
a) http
b) httpDecoder
c) httpConnection
d) httpd
6. Which of these method of MimeHeader is used to return the string equivalent of the values stores on MimeHeader?
a) string()
b) toString()
c) convertString()
d) getString()
7. What is the output of this program?
import java.net.*;
class networking {
public static void main(String[] args) throws Exception {
URL obj = new URL("http://www.gksquiz.blogspot.com/javamcq");
URLConnection obj1 = obj.openConnection();
System.out.print(obj1.getContentType());
}
}
a) html
b) text
c) html/text
d) text/html
8. Which of these is an instance variable of class httpd?
a) port
b) cache
c) log
d) All of the mentioned
9. Which of these is an instance variable of httpd that is a Hashtable?
a) port
b) cache
c) log
d) stopFlag
10. What is the output of this program?
import java.net.*;
class networking {
public static void main(String[] args) throws MalformedURLException {
URL obj = new URL("http://www.gksquiz.blogspot.com/javamcq");
System.out.print(obj.toExternalForm());
}
}
b) gksquiz.blogspot.com
c) www.gksquiz.blogspot.com
d) http://www.gksquiz.blogspot.com/javamcq