JavaP2 Theory Stud

Embed Size (px)

Citation preview

  • 8/14/2019 JavaP2 Theory Stud

    1/3

    Question Paper - Java Part 2Session 26-28 - Swing

    1- A _________ is a component that appears as a group of folders in a file cabineta) Tabbed pane

    b) Treec) Tables

    2- Which swing package contains the pluggable look and feel API ?a) javax.swing.plaf

    b) javax.swing.olugc) javax.swing.basicd) javax.swing.tree

    3- Which of the following are valid methods of the Abstract Button class? ( choose 3 )a) void setDisabledIcon()

    b) void setPressedIcon()c) void setSelectedIcon()d) void SelectionItem()

    Session 30-32 - JDBC1- The ________ uses local native libraries to communicate with the database

    a. JDBC-ODBC Bridge b. Native-API-Partly-Java Driver c. JDBC-Net-All-Java-Driver d. Native-Protocol-All-Java-Driver

    2- The Java software provides three JDBC product components, they area) the JDBC DriverManager facility

    b) the JDBC driver test suite

    c) the JDBC-ODBC bridged) the callable statement3- A __________ result set has a cursor that moves both forward and backward and

    can be moved to a particular row b) scrollablec) nonscrollabled) Unscrollable

    Session 34 Networking1) Which constructor of the ServerSocket class creates a server socket an the specified

    port with a queue length of 50?

    a) ServerSocket(int port) b) ServerSocket(int port,int maxQueue)c) ServerSocket(int port,int MaxQueue,InetAddress localAddress)

    2) Which of the following is a general purpose class for accessing the attributes of resource?

    a) URL Connection b) URL Encoder c) URL

  • 8/14/2019 JavaP2 Theory Stud

    2/3

    3) The _____, and_______, and_______ classes are for use with UDP ( choose 3 )a) DatagramPacket

    b) DatagramSocketc) MulticastSocketd) ServerSocket

    Session 36 RMI1) Which three of the following are classes of Java.rmi package?

    a) Naming b) MarshalledObjectc) RMISecurityManager d) Remote

    2) The bind() and rebind() method belongs to which class of the java.rmi package.a) Naming class

    b) RMISecurityManager classc) RMIloader class

    3) What will marshall and unmarshall your object? ( choose 2 )a) Sub

    b) Skeletonc) Clientd) Server

    4) Which of the following statements are true with reference to RMI ?1. RMI is language independent.2. RMI is platform independent.

    a) Only Statement 1 is true. b) Only Statement 2 is true.c) Both the statements are true.

    d) Both the statements are false.5) _______ classs is a sub-class of RemoteObject in Java RMI.

    a) RemoteServer b) Operationc) LogStreamd) MarshalledObject

    Session 38 - Java Beans1) Which interface methods allow a bean to execute in environments where a graphicaluser interface is not available?

    a) PropertyEditor b) Visivilityc) BeanInfod) Beans

    2) Which class of java beans package analyses a bean and contructs a BeanInfo objectthat describes the component?

    a) Introspector b) Beansc) BeanInfo

  • 8/14/2019 JavaP2 Theory Stud

    3/3

    3) _________ is used to obtain information about the fields, constructors of any classa) Introspection

    b) Persistencec) Reflectiond) Event

    e) Attribute

    Session 39 - Java Security1) Which option of jar file indicates manifest file not created?

    a) Jar M b) Jar tc) Jar md) Jar c

    2) _______ option of Jar command makes a Java archive file.a) JAR -c

    b) JAR -m

    c) JAR -vd) JAR f

    10/ The ______ consists of names across all cells within an enterprisea) Directory services

    b) Security servicesc) Remote services

    11/ The _______ method of the ActivationDesc class returns the object containingserialized informaiona) getData()

    b) getGroupData()c) getRestartModel()

    16/ Which of the following classes in java.lang.reflect package contains integer constantsand static methods?a) Constructors

    b) Modifiersc) Membersd) Arrays