Win a copy of Head First Android this week in the Android forum!

julius hock

Greenhorn
+ Follow
since Apr 06, 2006
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by julius hock

A free mock exam question as below:
Which of the following statements about Home methods in a bean class is incorrect for Container Managed Persistence [choose 1]:
A: The method must not access relationships.
B. The throws clause of the method may include the java.rmi.RemoteException.
C. The method must not access the bean's persistence state.
D. The method cannot be declared static.
E. The throws clause may include any exceptions defined by your application.

The answer is B. Isnt the RemoteException is allowed to be thrown by home method?
Any help would be much appreciated.
May i know what are the exceptions thrown by methods in EJBHome, EJBObject, EJBLocalHome and EJBLocalObject?
Hi,

I tried to consume an external third party web service url. When i was generating stub from WSDL, error given was "No Service Endpoints Found".

Any idea for me to check what goes wrong with the web service url? or could it due to firewall?


p/s: I cant put the wsdl here, but will send via email to anyone who is willing to help.
15 years ago
I'm wondering what is the different between
setAttribute("key", new X()); //print "B"
setAttribute("key", "x") // print "UB";
Question 55.
15. req.getSession().setAttribute("key", new X());
16. req.getSession().setAttribute("key", new X());
17. req.getSession().setAttribute("key", "x");
18. req.getSession().removeAttribute("key");

public void valueBound(HttpSessionBindingEvent event){
System.out.println("B");
}

public void valueUnbound(HttpSessionBindingEvent event){
System.out.println("UB");
}

Answer: B. BBUBUB


Any help would be much appreciated.
In HFSJ book -> Scriptless JSPs chapter -> Mock Exam Chapter 8 -> pg. 417 -> question 2.

Given that a web application stores the webmaster email address in the servlet context initialization parameter called master-email. Which retrieves that value?
why is the A. wrong? Can anyone explain?

A. <a href='mailto:${initParam.master-email}'>email me</a>

Thanks.