Well, maybe I'm wrong on this because this is only my first Tapestry
app (although large one), but from what I'm noticing is a common
generic patten.

Most page methods are really specific to a given page. Seldom when you
inject one page to another will you need to see every single method of
that page. To me it's actually dangerious and "ugly" to expose all
methods by default.  At best, when you derive one page from another
you'd want to inherit protected/public methods, but why make all
methods public by default?

I think only public page methods should be those that would be exposed
to another page via injection. All other methods should be protected.

Why would that be a bad design? To me it looks like a natural thing?

If my reasoning is incorrect please let me know. I'm always looking
for ways to learn more :-)

Adam



On 3/26/06, Mike Snare <[EMAIL PROTECTED]> wrote:
> Sounds kind of like a design issue.  If you really need to access it
> so badly from a non-subclass/non-package class, should it really be
> protected?
>
> -Mike
>
> On 3/26/06, Adam Zimowski <[EMAIL PROTECTED]> wrote:
> > Yeah, thanks, that's a valid workaround but...  In fact the method
> > which I have is already a facade to another. I don't want to create
> > facades as that's more code to maintain.. It would be neat if I could
> > just declare a method protected since other pages should not know
> > about it.
> >
> > adam
> >
> > On 3/26/06, Diogenes Moreira <[EMAIL PROTECTED]> wrote:
> > > Is simple, you may create a facade method in the same or other class.
> > >
> > > package my.corp.packageName
> > >
> > > public class FacadeClass {
> > > ...
> > >     public MyData  myMethodName(){
> > >         return  myClass.myMethodName();
> > >     }
> > >
> > > ....
> > > }
> > >
> > >
> > > 2006/3/25, Adam Zimowski <[EMAIL PROTECTED]>:
> > > > Hi,
> > > >
> > > > I'm not sure if this should be OGNL forum question, or something that
> > > > can be addressed by Tapestry. Seems like OGNL requires methods be
> > > > public. Anybody knows of a workaround to use protected scope methods
> > > > for OGNL calls?
> > > >
> > > > Regards, Adam
> > > >
> > > > ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > > For additional commands, e-mail: [EMAIL PROTECTED]
> > > >
> > > >
> > >
> > >
> > > --
> > > Diogenes A Moreira
> > > Project Manager
> > >
> > > PLEASE NOTE
> > > This message, along with any attachments, may be confidential or
> > > legally privileged.  It is intended only for the named person(s), who
> > > is/are the only authorized recipients. If this message has reached you
> > > in error, kindly destroy it without review and notify the sender
> > > immediately. Thank you for your help.
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to