Deck 12: Java RMI and Swing Framework

Full screen (f)
exit full mode
Question
The default layout manager of an Applet is

A)Flowlayout
B)Gridlayout
C)BorderLayout
D)BoxLayout
Use Space or
up arrow
down arrow
to flip the card.
Question
The processes that participate in supporting remote method invocation are

A)Client
B)Server
C)Object Registry
D)All of the above
Question
Through the design mode of a builder tool, we use ___ or ____ to customize the bean.

A)Property sheet
B)Bean customizer
C)Either (a) or (c)
D)None of the above
Question
Swing is a ___________ framework

A)connection-based
B)component-based
C)platform-based
D)None of the above
Question
How many kinds of classes can be used in Java RMI?

A)One
B)Two
C)Three
D)Four
Question
Which method is used to enable an event for a particular object?

A)enableEvent()
B)enable()
C)enableObject()
D)enableEvents()
Question
How would you detect a keypress in a JComboBox?

A)Add a KeyListener to the JComboBox
B)Add a KeyListener to the JComboBox's editor component
C)Either (a) or (b)
D)None of the above
Question
Which Swing methods are thread-safe?

A)repaint()
B)revalidate()
C)invalidate()
D)all of the above
Question
Which of the following is not true?

A)The Frame class extends Window
B)The CheckboxMenuItem class extends the MenuItem class
C)JComponent is a subclass of Container
D)None of the above
Question
What is the correct way to write a JavaScript array?

A)var txt = new Array:1=("tim")2=("kim")3=("jim")
B)var txt = new Array(1:"tim",2:"kim",3:"jim")
C)var txt = new Array="tim","kim","jim")
D)var txt = new Array("tim","kim","jim")
Question
What is the correct JavaScript syntax to insert a comment that has more than one line?

A)
B)/*This comment has more than one line*/
C)//This comment has more than one line//
D)
Question
What is Remote method invocation (RMI)?

A)RMI allows us to invoke a method of java object that executes on another machine.
B)RMI allows us to invoke a method of java object that executes on another Thread in multithreaded programming.
C)RMI allows us to invoke a method of java object that executes parallely in same machine.
D)None of the mentioned
Question
Which of this package is used for remote method invocation?

A)java.applet
B)java.rmi
C)java.lang.rmi
D)java.lang.reflect
Question
Which of these methods are member of Remote class?

A)checkIP()
B)addLocation()
C)AddServer()
D)None of the mentioned
Question
Which of these Exceptions is thrown by remote method?

A)RemoteException
B)InputOutputException
C)RemoteAccessException
D)RemoteInputOutputException
Question
Which of this class is used for creating a client for server-client operations?

A)serverClientjava
B)Client.java
C)AddClient.java
D)ServerClient.java
Question
Which of this package is used for all the text related modifications?

A)java.text
B)java.awt
C)java.lang.text
D)java.text.mofify
Question
Which of this package contains classes and interfaces for networking?

A)java.io
B)java.util
C)java.net
D)java.network
Question
Which of these is superclass of ContainerEvent class?

A)WindowEvent
B)ComponentEvent
C)ItemEvent
D)InputEvent
Question
Which of these events is generated when the size os an event is changed?

A)ComponentEvent
B)ContainerEvent
C)FocusEvent
D)InputEvent
Question
Which of these methods can be used to obtain the reference to the container that generated a ContainerEvent?

A)getContainer()
B)getContainerCommand()
C)getActionEvent()
D)getContainerEvent()
Question
To locate a remote object with a name t at port 7000 on host panda.armstrong.edu, use

A)Remote remoteObj = Name.lookup("rmi://panda.armstrong.edu:7000/t");
B)Remote remoteObj = Name.lookup("//panda.armstrong.edu:7000/t");
C)Remote remoteObj = Name.lookup("http://panda.armstrong.edu:7000/t");
D)Remote remoteObj = Naming.lookup("rmi://panda.armstrong.edu:7000/t");
Question
____________ is a subinterface of java.rmi.Remote that defines the methods for the server object.

A)Server stub
B)Server implementation
C)Server object interface
D)RMI Registry
Question
Each remote object has a unique name identified by an URL with the protocol rmi as follows:

A)http://host:port/name
B)//host:port/name
C)http://host/name
D)rmi://host:port/name
Question
__________ provides the naming services for the server to register the object and for the client to locate the object.

A)Server stub
B)RMI Registry
C)Server implementation
D)Server Skeleton
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/25
auto play flashcards
Play
simple tutorial
Full screen (f)
exit full mode
Deck 12: Java RMI and Swing Framework
1
The default layout manager of an Applet is

A)Flowlayout
B)Gridlayout
C)BorderLayout
D)BoxLayout
Flowlayout
2
The processes that participate in supporting remote method invocation are

A)Client
B)Server
C)Object Registry
D)All of the above
All of the above
3
Through the design mode of a builder tool, we use ___ or ____ to customize the bean.

A)Property sheet
B)Bean customizer
C)Either (a) or (c)
D)None of the above
Either (a) or (c)
4
Swing is a ___________ framework

A)connection-based
B)component-based
C)platform-based
D)None of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
5
How many kinds of classes can be used in Java RMI?

A)One
B)Two
C)Three
D)Four
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
6
Which method is used to enable an event for a particular object?

A)enableEvent()
B)enable()
C)enableObject()
D)enableEvents()
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
7
How would you detect a keypress in a JComboBox?

A)Add a KeyListener to the JComboBox
B)Add a KeyListener to the JComboBox's editor component
C)Either (a) or (b)
D)None of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
8
Which Swing methods are thread-safe?

A)repaint()
B)revalidate()
C)invalidate()
D)all of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
9
Which of the following is not true?

A)The Frame class extends Window
B)The CheckboxMenuItem class extends the MenuItem class
C)JComponent is a subclass of Container
D)None of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
10
What is the correct way to write a JavaScript array?

A)var txt = new Array:1=("tim")2=("kim")3=("jim")
B)var txt = new Array(1:"tim",2:"kim",3:"jim")
C)var txt = new Array="tim","kim","jim")
D)var txt = new Array("tim","kim","jim")
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
11
What is the correct JavaScript syntax to insert a comment that has more than one line?

A)
B)/*This comment has more than one line*/
C)//This comment has more than one line//
D)
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
12
What is Remote method invocation (RMI)?

A)RMI allows us to invoke a method of java object that executes on another machine.
B)RMI allows us to invoke a method of java object that executes on another Thread in multithreaded programming.
C)RMI allows us to invoke a method of java object that executes parallely in same machine.
D)None of the mentioned
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
13
Which of this package is used for remote method invocation?

A)java.applet
B)java.rmi
C)java.lang.rmi
D)java.lang.reflect
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
14
Which of these methods are member of Remote class?

A)checkIP()
B)addLocation()
C)AddServer()
D)None of the mentioned
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
15
Which of these Exceptions is thrown by remote method?

A)RemoteException
B)InputOutputException
C)RemoteAccessException
D)RemoteInputOutputException
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
16
Which of this class is used for creating a client for server-client operations?

A)serverClientjava
B)Client.java
C)AddClient.java
D)ServerClient.java
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
17
Which of this package is used for all the text related modifications?

A)java.text
B)java.awt
C)java.lang.text
D)java.text.mofify
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
18
Which of this package contains classes and interfaces for networking?

A)java.io
B)java.util
C)java.net
D)java.network
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
19
Which of these is superclass of ContainerEvent class?

A)WindowEvent
B)ComponentEvent
C)ItemEvent
D)InputEvent
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
20
Which of these events is generated when the size os an event is changed?

A)ComponentEvent
B)ContainerEvent
C)FocusEvent
D)InputEvent
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
21
Which of these methods can be used to obtain the reference to the container that generated a ContainerEvent?

A)getContainer()
B)getContainerCommand()
C)getActionEvent()
D)getContainerEvent()
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
22
To locate a remote object with a name t at port 7000 on host panda.armstrong.edu, use

A)Remote remoteObj = Name.lookup("rmi://panda.armstrong.edu:7000/t");
B)Remote remoteObj = Name.lookup("//panda.armstrong.edu:7000/t");
C)Remote remoteObj = Name.lookup("http://panda.armstrong.edu:7000/t");
D)Remote remoteObj = Naming.lookup("rmi://panda.armstrong.edu:7000/t");
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
23
____________ is a subinterface of java.rmi.Remote that defines the methods for the server object.

A)Server stub
B)Server implementation
C)Server object interface
D)RMI Registry
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
24
Each remote object has a unique name identified by an URL with the protocol rmi as follows:

A)http://host:port/name
B)//host:port/name
C)http://host/name
D)rmi://host:port/name
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
25
__________ provides the naming services for the server to register the object and for the client to locate the object.

A)Server stub
B)RMI Registry
C)Server implementation
D)Server Skeleton
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
locked card icon
Unlock Deck
Unlock for access to all 25 flashcards in this deck.