My friend, I must admit that I have never applied inheritance on static
nested classes in my life.
(Not at least that I can remember :) )
I'm not to sure what the minimal access control level for static nested
classes is from point of nested inheritance and Struts system.
Maybe it has to do something with like reflection process that it needs that
nested class public access. :)
No idea, maybe someone else can comment on this issue?
Quite interested myself to know the answer to this one.

--Alen


----- Original Message -----
From: "Paul Harrison" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>;
<[EMAIL PROTECTED]>
Sent: Thursday, June 19, 2003 1:49 AM
Subject: Re: Problems with an inherited getter in a derived bean


> thanks for confirming that this should work - one fact that I omitted in
> my original mailing was that the classes were inner classes
>
> i.e. it  was the PostCode.Area class that is in the collection
>
> public class PostCode
> {
>      protected static class Pbase
>     {
>         protected String name;
>
>         public String getName()
>         {
>             return name;
>         }
>
>     }
>     public static class Area extends Pbase
>     {
>     }
> }
>
> I works it I change the access on the Pbase class to public, but do I
> have to ? I thought that it was legal to have derived classes increase
> the accessibility - I do not want to expose the Pbase class.... -
> however this is pushing the limits of my knowledge about what should be
> happening.....
>
>
> Alen Ribic wrote:
>
> >I'm doing the same thing in my current project successfully.
> >No problems in my specializes class.
> >
> >e.g.
> >
> >public abstract class BaseBusinessBean
> >    implements java.io.Serializable {
> >    protected int id;
> >    protected String description;
> >
> >    // getters/setters here
> >}
> >
> >e.g.
> >
> >public class Category
> >    extends BaseBusinessBean {
> >    // Category specific getters/setters
> >}
> >
> >
> >Now  I use Category class with no problem in my options for select box.
> >
> >You have code <snippet>?
> >
> >--Alen
> >
> >
> >
> >----- Original Message -----
> >From: "Paul Harrison" <[EMAIL PROTECTED]>
> >To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
> >Sent: Wednesday, June 18, 2003 4:55 PM
> >Subject: Problems with an inherited getter in a derived bean
> >
> >
> >
> >
> >>In my struts application, I have a base bean with a set of basic
> >>properties (e.g. name) and then I create various derived beans with
> >>their own extra properties. I have a problem with the <html:options> tag
> >>in that if I try to read a property  that is inherited from the base
> >>bean  from a collection of the derived beans
> >>
> >>i.e. I have a tag like this
> >>
> >><html:options collection="CountyList" property="name" />
> >>
> >> - I get an error saying
> >>
> >>No getter method available for property name for bean under name
> >>
> >>
> >CountyList
> >
> >
> >> and if I implement the getter in the derived bean the  error goes away.
> >>Is this known behaviour in struts - is seems like a bug to me (or
> >>perhaps a bug in commons-beanutils?) Can anyone comment....
> >>
> >>--
> >>Paul Harrison
> >>
> >>[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]
> >
> >
> >
> >
>
> --
> Paul Harrison
>
> [EMAIL PROTECTED]
> tel: 0161 428 2794
> mob: 07904025192
>
>
>
> ---------------------------------------------------------------------
> 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