aspose file tools*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes problem in tld while defining function which has to be used by EL Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "problem in tld while defining function which has to be used by EL" Watch "problem in tld while defining function which has to be used by EL" New topic
Author

problem in tld while defining function which has to be used by EL

Mayur Shinde
Greenhorn

Joined: Feb 15, 2012
Posts: 18
I am declaring one function in tld which i have to use through el, now problem is the class in which i am defining is suppose GenerateRandom.java and it is in default package, so what i have to declare in <function-class> tag, because generally we here specify the package name like <function-class>com.info.GenerateRandom</function-class>, i have tried declaring only class name like
<function-class>GenerateRandom</function-class>
Frits Walraven
Creator of Enthuware JWS+ V6
Bartender

Joined: Apr 07, 2010
Posts: 1696
    
  25

Hi Mayur,

I am declaring one function in tld which i have to use through el, now problem is the class in which i am defining is suppose GenerateRandom.java and it is in default package,

This cannot be done, put you class in a package

Regards,
Frits
Mayur Shinde
Greenhorn

Joined: Feb 15, 2012
Posts: 18
Frits Walraven wrote:Hi Mayur,

I am declaring one function in tld which i have to use through el, now problem is the class in which i am defining is suppose GenerateRandom.java and it is in default package,

This cannot be done, put you class in a package

Regards,
Frits


It is possible that my class is in default package.
Frits Walraven
Creator of Enthuware JWS+ V6
Bartender

Joined: Apr 07, 2010
Posts: 1696
    
  25

It is possible that my class is in default package.

Off course it is possible, but if you read the java specs, then the default package is only meant for testing purposes. As soon as application servers are involved: don't use the default package: it won't work, and if it by accident works it won't be portable.

Regards,
Frits
Mayur Shinde
Greenhorn

Joined: Feb 15, 2012
Posts: 18
Frits Walraven wrote:
It is possible that my class is in default package.

Off course it is possible, but if you read the java specs, then the default package is only meant for testing purposes. As soon as application servers are involved: don't use the default package: it won't

Thanks for above information
 
Consider Paul's rocket mass heater.
 
subject: problem in tld while defining function which has to be used by EL