第1题:
public class Threads2 implements Runnable { public void nun() { System.out.println(”run.”); throw new RuntimeException(”Problem”); } public static void main(String[] args) { Thread t = new Thread(new Threads2()); t.start(); System.out.println(”End of method.”); } } Which two can be results?()
第2题:
Your web application requires the adding and deleting of many session attributes during a complex usecase. A bug report has come in that indicates that an important session attribute is being deleted too soonand a NullPointerException is being thrown several interactions after the fact. You have decided to create asession event listener that will log when attributes are being deleted so you can track down when theattribute is erroneously being deleted. Which listener class will accomplish this debugging goal?()
第3题:
Given that t1 is a reference to a live thread, which is true?()
第4题:
What can cause a thread to become non-runnable?()
第5题:
Which two statements are true about using the isUserInRole method to implement security in a Java EEapplication?()
第6题:
You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5. The application must redirect the original URL to a different ASPX page. You need to ensure that the users cannot view the original URL after the page is executed. You also need to ensure that each page execution requires only one request from the client browser. What should you do?()
第7题:
You need to include a disclaimer to all sent messages in your organization. Some of the users require message encryption.How do you make sure that disclaimer can be included in encrypted messages?()
第8题:
Calling the yield method.
Calling the wait method on an object.
Calling the notify method on an object.
Calling the notifyAll method on an object.
Calling the start method on another Thread object.
第9题:
Exiting from a synchronized block.
Calling the wait method on an object.
Calling the notify method on an object.
Calling the notifyAll method on an object.
第10题:
Extend java.lang.Thread and override the run method.
Extend java.lang.Runnable and override the start method.
Implement java.lang.thread and implement the run method.
Implement java.lang.Runnable and implement the run method.
Implement java.lang.Thread and implement the start method.
第11题:
Configure threadOne to run at a lower priority.
Configure threadTwo to run at a higher priority.
Use a WaitCallback delegate to synchronize the threads.
Call the Sleep method of threadOne.
Call the SpinLock method of threadOne.
第12题:
Compilation fails because the hashCode method is not overridden.
A HashSet could contain multiple Person objects with the same name.
All Person objects will have the same hash code because the hashCode method is not overridden.
If a HashSet contains more than one Person object with name="Fred", then removing another Person, also with name="Fred", will remove them all.
第13题:
Which two CANNOT directly cause a thread to stop executing?()
第14题:
Given this method in a class: public String toString() { StringBuffer buffer = new StringBuffer(); buffer.append(‟<‟); buffer.append(this.name); buffer.append(‟>‟); return buffer.toString(); } Which is true?()
第15题:
public class Person { private name; public Person(String name) { this.name = name; } public boolean equals(Object o) { if( !o instanceof Person ) return false; Person p = (Person) o; return p.name.equals(this.name); } } Which is true?()
第16题:
Which statement is true?()
第17题:
Your application uses two threads, named threadOne and threadTwo. You need to modify the code to prevent the execution of threadOne until threadTwo completes execution. What should you do?()
第18题:
You use Microsoft .NET Framework 4 to create an application. The application performs resource-intensive calculations that consist of multiple layers of nested looping. The application will be deployed to servers that contain varying hardware configurations. You need to ensure that the application utilizes CPU resources on the server in the most efficient manner. You want to achieve this goal by using the minimum amount of code. What should you do?()
第19题:
You need to implement an authentication method on SQL4. The TravelOnline database will be accessed through a Web services application. You need to make the authentication method as secure as possible.What should you do?()
第20题:
Use the AsOrdered method.
Use the SelectMany method.
Use the AutoBuffered option in the WithMergeOptions method.
Use the WithExecutionMode method with the ParallelExecutionMode.ForceParallelism parameter.
第21题:
Compilation fails because the hashCode method is not overridden.
A HashSet could contain multiple Person objects with the same name.
All Person objects will have the same hash code because the hashCode method is not overridden.
If a HashSet contains more than one Person object with name=”Fred”, then removing another person, also with name=”Fred”, will remove them all.
第22题:
Configure threadOne to run at a lower priority.
Configure threadTwo to run at a higher priority.
Use a WaitCallback delegate to synchronize the threads.
Call the Sleep method of threadOne.
Call the SpinLock method of threadOne.
第23题:
99
100
101
999
1000