I don't think the container can get or set private fields.
Would't you get an IllegalAccessException or something like that? And I
think one of the side effects of requiring so many things to be public is
that it reinforces the EJB architecture - it doesn't matter if your fields
are public, because the only way things can interact with your EJB is via
its interface.
BTW, to return to the original point, I think the reason you saw
these messages is because in the BETA-PROD, we turned the bean verifier on
by default, whereas before it was off by default. Once you're sure your
beans are all correct, you can turn it off again (in jboss.jcml).
Aaron
On Thu, 14 Sep 2000, Juha-P Lindfors wrote:
> getDeclaredFields() would return all fields, including private, right?
>
> Anyhow, with EJB2.0 all access to CMP fields will go through accessor
> methods, so it would seem that at least then it is not necessary to keep
> these fields public (though the spec draft doesn't change the requirements
> for this, CMP fields are still required to be public).
>
> Not sure why this requirement was made in the first place. Although since
> the container is the only one accessing the bean class I guess it doesn't
> make that much difference but still it seems to go against the coding
> practice many OO programmers use.
>
> -- Juha
>
>
>
>
> --
> --------------------------------------------------------------
> To subscribe: [EMAIL PROTECTED]
> To unsubscribe: [EMAIL PROTECTED]
> Problems?: [EMAIL PROTECTED]
>
--
--------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Problems?: [EMAIL PROTECTED]