• 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

OOP - jar protected method?

 
Ranch Hand
Posts: 294
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all
I have a base class � WebContainer from which I derive two classes, Request class and Response class.
WebContainer is a like aMap and donate both get() and set() methods for both derived classes .
The entire project is packaged into a jar and distributed to other development teams.
The team's has no need of calling request.set(objId) or response.get(objId), they only use request.get(objId) and
All set() method usages are restricted to classes in the jar file (sevarel of packages) .
What I can do is declare the request.set , and response.get methods as deprecated, so the teams will no not to use them ,
Is there any other way I can prevent them from accessing these methods?
Thank you
Sharon whipple


 
It means our mission is in jeapordy! Quick, read this tiny ad!
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic