Win a copy of Murach's MySQL this week in the JDBC and Relational Databases forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Can these methods exist...

 
Greenhorn
Posts: 17
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
I have a very fundamental doubt.
Can we have a method definition in our Bean's Implementation class without declaring it in the Remote Interface & Home Interface. If yes, that means our Bean Class will have this method, but clients won't have access to this method, indeed makeing it a useless method (or, is it usefull in some cases?)
Please Clarify...
Thanks in advance..
 
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, u can have a method in the bean class and not have it declare it in the remote i/f..this mean the client cannot use that method..but that method may be called from any other business method..which the client can access throught remote i/f ..If some method is useless why would any one define that method in first place?

Originally posted by Yogesh Mathur:
Hi!
I have a very fundamental doubt.
Can we have a method definition in our Bean's Implementation class without declaring it in the Remote Interface & Home Interface. If yes, that means our Bean Class will have this method, but clients won't have access to this method, indeed makeing it a useless method (or, is it usefull in some cases?)
Please Clarify...
Thanks in advance..

 
Ranch Hand
Posts: 346
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I guess , yes
no harm in having such a method but it dont necessarily have to be useless
it can be a private method or some sort of 'utility'method. If there is some functionality common to more than one methods which u r exposing through interfaces , then that functionality can be kept in such a utility method.
just 1.5 cents of mine
 
Ranch Hand
Posts: 977
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, yes you can have such method. A commom use of doing so is to have a method who performs some kind of log service, and the clients doesn�t have to know about it.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic