You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Andre de Jesus <an...@tektix.com> on 2001/11/26 17:19:21 UTC
Undocumented change in 1.4 JDK can cause problems with tag libraries
Hi
As SUN says, the Introspector class in the beans API has been
reimplemented in the most recent version of the JDK (1.4.0 beta3).
In the previous versions, the simultaneous presence in a tag library
extension of a getter method and a setter method of diferent types both
methods would apparently cause no problems:
public void setThis(String str);
public boolean isThis();
(both methods would be recognized).
But now, only the getter method (boolean) is recognized. Probably this
is the correct behavior, since methods of different types are
contradictory, but nevertheless I thought to say this because it has
relevance to this list and can break code that relied on the incorrect
previous behavior.
Thank you
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Undocumented change in 1.4 JDK can cause problems with tag
libraries
Posted by "Craig R. McClanahan" <cr...@apache.org>.
This restriction is not new -- it has been in the JavaBeans spec since the
very beginning. If you have getter and setter methods that have
different types (or you have multiple setter properties with different
types), then your application is broken and is guaranteed to be
non-portable.
People who don't read the specs are responsible for their own problems
when they rely on things that "just happen to work".
Craig McClanahan
On Mon, 26 Nov 2001, Andre de Jesus wrote:
> Date: Mon, 26 Nov 2001 16:19:21 +0000
> From: Andre de Jesus <an...@tektix.com>
> Reply-To: Tomcat Developers List <to...@jakarta.apache.org>
> To: tomcat-dev <to...@jakarta.apache.org>
> Subject: Undocumented change in 1.4 JDK can cause problems with tag
> libraries
>
> Hi
>
> As SUN says, the Introspector class in the beans API has been
> reimplemented in the most recent version of the JDK (1.4.0 beta3).
> In the previous versions, the simultaneous presence in a tag library
> extension of a getter method and a setter method of diferent types both
> methods would apparently cause no problems:
>
> public void setThis(String str);
>
> public boolean isThis();
>
> (both methods would be recognized).
>
> But now, only the getter method (boolean) is recognized. Probably this
> is the correct behavior, since methods of different types are
> contradictory, but nevertheless I thought to say this because it has
> relevance to this list and can break code that relied on the incorrect
> previous behavior.
>
> Thank you
>
>
>
> --
> To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>