单选题Which method must be defined by a class implementing the java.lang.Runnable interface? ()A void run()B public void run()C public void start()D void run(int priority)E public void run(int priority)F public void start(int priority)

单选题
Which method must be defined by a class implementing the java.lang.Runnable interface? ()
A

 void run()

B

 public void run()

C

 public void start()

D

 void run(int priority)

E

 public void run(int priority)

F

 public void start(int priority)


参考解析

解析: 暂无解析

相关考题:

Click the Exhibit button. Given:Which statement is true if a TestException is thrown on line 3 of class B? () A.Line 33 must be called within a try block.B.The exception thrown by method1 in class A is not required to be caught.C.The method declared on line 31 must be declared to throw a RuntimeException.D.On line 5 of class A, the call to method2 of class B does not need to be placed in a try/catch block.

Which two statements are true about the hashCode method?()A、 The hashCode method for a given class can be used to test for object equality and object inequality for that class.B、 The hashCode method is used by the java.util.SortedSet collection class to order theelements within that set.C、 The hashCode method for a given class can be used to test for object inequality, but NOT object equality, for that class.D、 The only important characteristic of the values returned by a hashCode method is that the distribution of values must follow a Gaussian distribution.E、 The hashCode method is used by the java.util.HashSet collection class to group the elements within that set into hash buckets for swift retrieval.

A custom JSP tag must be able to support an arbitrary number of attributes whose names are unknown when the tag class is designed.  Which two are true? ()A、 A  element in the echo tag LTD must have the value JSPB、 The echo tag handler must define the setAttribute (String key, String value) methodC、 The true element must appear in the echo tag TLDD、 The class implementing the echo tag handler must implement the javax.sevlet.jsp.tagext.IterationTag interfaceE、 The class implementing the echo tag handler must implement the javax.sevlet.jsp.tagext.DynamicAttributes interface

1. public class a {  2. public void method1() {  3. try {  4. B b=new b();  5. b.method2();  6. // more code here  7. } catch (TestException te) {  8. throw new RuntimeException(te);  9. }  10. }  11. }  1. public class b {  2. public void method2() throws TestException {  3. // more code here  4. }  5. }  1. public class TestException extends Exception {  2. }  Given:  31. public void method() {  32. A a=new a();  33. a.method1();  34. }  Which is true if a TestException is thrown on line 3 of class b?()A、 Line 33 must be called within a try block.B、 The exception thrown by method1 in class a is not required to be caught.C、 The method declared on line 31 must be declared to throw a RuntimeException.D、 On line 5 of class a, the call to method2 of class b does not need to be placed in a try/catch block.

Which statements concerning the methods notify() and notifyAll() are true?  A、Instances of class Thread have a method called notify().B、A call to the method notify() will wake the thread that currently owns the monitor of the object.C、The method notify() is synchronized.D、The method notifyAll() is defined in class Thread.E、When there is more than one thread waiting to obtain the monitor of an object, there is no way to be  sure which thread will be notified by the notify() method.

What is a limitation of implementing uRPF?()A、MPLS LDP must be enabled.B、BGP routing protocol must be running.C、Named access-lists must be configured.D、Symmetrical routing is required.E、Domain name must be defined

Which method must be defined by a class implementing the java.lang.Runnable interface? () A、 void run()B、 public void run()C、 public void start()D、 void run(int priority)E、 public void run(int priority)F、 public void start(int priority)

It is desirable that a certain method within a certain class can only be accessed by classes that are defined within the same package as the class of the method. How can such restrictions be enforced?()  A、Mark the method with the keyword public.B、Mark the method with the keyword protected.C、Mark the method with the keyword private.D、Mark the method with the keyword package.E、Do not mark the method with any accessibility modifiers.

Which methods from the String and StringBuffer classes modify the object on which they are called?()  A、The charAt() method of the String class.B、The toUpperCase() method of the String class.C、The replace() method of the String class.D、The reverse() method of the StringBuffer class.E、The length() method of the StringBuffer class.

A developer wants too use EL to invoke a function using S{my:bloof(“foof”)}. Which is always true?()A、 The method invoked by this function must be statie.B、 The function class must implement the Function interface.C、 The expression is NOT a valid EL expression for invoking a function.D、 The function must be declared in a web.xml file using the  element.E、 The function class must have a method with the signature:Void bloof (java.lang.Strings)

Given an EL function declared with:11.  12.spin 13.com.example.Spinner 14. 15.java.lang.String spinIt() 16. 17. Which two are true?()A、The function method must have the signature: public String spin().B、The method must be mapped to the logical name "spin" in the web.xml file.C、The function method must have the signature: public String spinIt().D、The function method must have the signature public static String spin().E、The function method must have the signature: public static String spinIt().F、The function class must be named Spinner, and must be in the package com.example.

You are implementing an ASP. NET MVC 2 Web application. You add a controller named Company Controller. You need to modify the application to handle the URL path /company/info. Which two actions should you perform?()A、Add the following method to the CompanyController class. Function Info() As ActionResult   Return View() End FunctionB、Add the following method to the CompanyController class. Function Company_Info() As ActionResult  Return View() End FunctionC、Right-click the Views folder, and select View from the Add submenu to create the view for the action.D、Right-click inside the action method in the CompanyController class, and select Add View to create a view for the action

You are developing a custom-collection class.You need to create a method in your class. You need to ensure that the method you create in your class returns a type that is compatible with the Foreach statement. Which criterion should the method meet?()A、The method must return a type of either IEnumerator or IEnumerable.B、The method must return a type of IComparable.C、The method must explicitly contain a collection.D、The method must be the only iterator in the class.

单选题A developer wants too use EL to invoke a function using S{my:bloof(“foof”)}. Which is always true?()A The method invoked by this function must be statie.B The function class must implement the Function interface.C The expression is NOT a valid EL expression for invoking a function.D The function must be declared in a web.xml file using the  element.E The function class must have a method with the signature:Void bloof (java.lang.Strings)

单选题It is desirable that a certain method within a certain class can only be accessed by classes that are defined within the same package as the class of the method. How can such restrictions be enforced?()AMark the method with the keyword public.BMark the method with the keyword protected.CMark the method with the keyword private.DMark the method with the keyword package.EDo not mark the method with any accessibility modifiers.

多选题Which of the following statements about variables and scope are true?()ALocal variables defined inside a method are destroyed when the method is exited.BLocal variables are also called automatic variables.CVariables defined outside a method are created when the object is constructed.DA method parameter variable continues to exist for as long as the object is needed in which the method is defined.

单选题Which methods from the String and StringBuffer classes modify the object on which they are called?()AThe charAt() method of the String class.BThe toUpperCase() method of the String class.CThe replace() method of the String class.DThe reverse() method of the StringBuffer class.EThe length() method of the StringBuffer class.

多选题You want to create a filter for your web application and your filter will implement javax.servlet.Filter. Which two statements are true?()AYour filter class must implement an init method and a destroy method.BYour filter class must also implement javax.servlet.FilterChain.CWhen your filter chains to the next filter, it should pass the same arguments it received in its doFiltermethod.DThe method that your filter invokes on the object it received that implements javax.servlet.FilterChaincan invoke either another filter or a servlet.EYour filter class must implement a doFilter method that takes, among other things, anHTTPServletRequest object and an HTTPServletResponse object.

多选题A custom JSP tag must be able to support an arbitrary number of attributes whose names are unknown when the tag class is designed.  Which two are true? ()AA  element in the echo tag LTD must have the value JSPBThe echo tag handler must define the setAttribute (String key, String value) methodCThe true element must appear in the echo tag TLDDThe class implementing the echo tag handler must implement the javax.sevlet.jsp.tagext.IterationTag interfaceEThe class implementing the echo tag handler must implement the javax.sevlet.jsp.tagext.DynamicAttributes interface

多选题Which of the following statements about variables and their scopes are true? ()AInstance variables are member variables of a class.BInstance variables are declared with the static keyword.CLocal variables defined inside a method are created when the method is executed.DLocal variables must be initialized before they are used.

单选题1. public class a {  2. public void method1() {  3. try {  4. B b=new b();  5. b.method2();  6. // more code here  7. } catch (TestException te) {  8. throw new RuntimeException(te);  9. }  10. }  11. }  1. public class b {  2. public void method2() throws TestException {  3. // more code here  4. }  5. }  1. public class TestException extends Exception {  2. }  Given:  31. public void method() {  32. A a=new a();  33. a.method1();  34. }  Which is true if a TestException is thrown on line 3 of class b?()A Line 33 must be called within a try block.B The exception thrown by method1 in class a is not required to be caught.C The method declared on line 31 must be declared to throw a RuntimeException.D On line 5 of class a, the call to method2 of class b does not need to be placed in a try/catch block.

单选题You are modifying an existing Windows Communication Foundation (WCF) service that is defined as follows:[ServiceContract]public interface IMessageProcessor { [OperationContract] void ProcessMessages( );}public class MessageProcessor: IMessageProcessor { public void ProcessMessage( ); SubmitOrder( );}SubmitOrder makes a call to another service. The ProcessMessage method does not perform as expected under a heavy load.You need to enable processing of multiple messages. New messages must only be processed when the ProcessMessage method is not processing requests,or when it is waiting for calls to SubmitOrder to return.Which attribute should you apply to the MessageProcessor class?()ACallbackBehavior(ConcurrencyMode=ConcurencyMode.Reentrant)BCallbackBehavior(ConcurrencyMode=ConcurrencyMode.Multiple)CServiceBehavior(ConcurrencyMode=ConcurrencyMode.Reentrant)DServiceBehavior(ConcurrencyMode=ConcurrencyMode.Multiple)

单选题You are developing a custom-collection class.You need to create a method in your class. You need to ensure that the method you create in your class returns a type that is compatible with the Foreach statement. Which criterion should the method meet?()AThe method must return a type of either IEnumerator or IEnumerable.BThe method must return a type of IComparable.CThe method must explicitly contain a collection.DThe method must be the only iterator in the class.

多选题Which two statements are true about the hashCode method?()AThe hashCode method for a given class can be used to test for object equality and object inequality for that class.BThe hashCode method is used by the java.util.SortedSet collection class to order theelements within that set.CThe hashCode method for a given class can be used to test for object inequality, but NOT object equality, for that class.DThe only important characteristic of the values returned by a hashCode method is that the distribution of values must follow a Gaussian distribution.EThe hashCode method is used by the java.util.HashSet collection class to group the elements within that set into hash buckets for swift retrieval.

单选题What is a limitation of implementing uRPF?()AMPLS LDP must be enabled.BBGP routing protocol must be running.CNamed access-lists must be configured.DSymmetrical routing is required.EDomain name must be defined

多选题Given an EL function declared with:11.  12.spin 13.com.example.Spinner 14. 15.java.lang.String spinIt() 16. 17. Which two are true?()AThe function method must have the signature: public String spin().BThe method must be mapped to the logical name spin in the web.xml file.CThe function method must have the signature: public String spinIt().DThe function method must have the signature public static String spin().EThe function method must have the signature: public static String spinIt().FThe function class must be named Spinner, and must be in the package com.example.

多选题Which statements concerning the methods notify() and notifyAll() are true?AInstances of class Thread have a method called notify().BA call to the method notify() will wake the thread that currently owns the monitor of the object.CThe method notify() is synchronized.DThe method notifyAll() is defined in class Thread.EWhen there is more than one thread waiting to obtain the monitor of an object, there is no way to be  sure which thread will be notified by the notify() method.