Re: Boolean Property Expression

2012-04-05 Thread jeshurun
Has there been any updates on this? I noticed that this still exists on 5.3.

--
View this message in context: 
http://tapestry.1045711.n5.nabble.com/Boolean-Property-Expression-tp2424958p5621510.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Boolean Property Expression

2009-10-13 Thread Howard Lewis Ship
It wouldn't be the first time that T5 "pencilled outside the lines" of
the JavaBeans specification ... the other being allowing case
insensitive access to properties.

On Tue, Oct 13, 2009 at 3:01 PM, Benny Law  wrote:
> Would it be reasonable to request that "is" be recognized as a valid getter
> prefix for java.lang.Boolean properties in Tapestry? (Hibernate allows it.)
> Howard?
>
> Benny
>
> On Tue, Oct 13, 2009 at 1:01 PM, Benny Law  wrote:
>
>> Thanks for your speedy response, Lance. I wish java.lang.Boolean were
>> included. The reason I use that instead of primitive boolean is that I also
>> use the User object for query by example in Hibernate, so I need to be able
>> to set the property to null for the property to be ignored. I would
>> appreciate your thoughts on this.
>>
>> Benny
>>
>>
>> On Tue, Oct 13, 2009 at 12:48 PM, Lance Java 
>> wrote:
>>
>>> The java beans spec only states that "is" can be used for boolean, it does
>>> not mention java.lang.Boolean.
>>>
>>>
>>> https://cds.sun.com/is-bin/INTERSHOP.enfinity/WFS/CDS-CDS_Developer-Site/en_US/-/USD/viewproductdetail-start?productref=7224-javabeans-1.01-fr-spec-oth-js...@cds-cds_developer
>>> 2009/10/13Benny
>>>  Law <
>>> benny.mk@gmail.com>
>>>
>>> > Hi all,
>>> >
>>> > I just came across something that seems odd to me: I have a User object
>>> > which has a Boolean property with isMobileUser() and
>>> setMobileUser(Boolean)
>>> > as getter and setter. When I used ${user.mobileUser} in my template
>>> (user
>>> > is
>>> > a page property), Tapestry complained about the expression being
>>> > write-only.
>>> > Apparently, it did not recognize the getter with the "is" prefix.
>>> Changing
>>> > the expression to ${user.isMobileUser()} fixed the problem.
>>> >
>>> > Can somebody confirm whether Tapestry recognizes the "is" getter prefix
>>> for
>>> > Boolean (not boolean) properties?
>>> >
>>> > Thanks,
>>> >
>>> > Benny Law
>>> >
>>>
>>
>>
>



-- 
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to
learn how I can get you up and productive in Tapestry fast!

(971) 678-5210
http://howardlewisship.com

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: Boolean Property Expression

2009-10-13 Thread Benny Law
Would it be reasonable to request that "is" be recognized as a valid getter
prefix for java.lang.Boolean properties in Tapestry? (Hibernate allows it.)
Howard?

Benny

On Tue, Oct 13, 2009 at 1:01 PM, Benny Law  wrote:

> Thanks for your speedy response, Lance. I wish java.lang.Boolean were
> included. The reason I use that instead of primitive boolean is that I also
> use the User object for query by example in Hibernate, so I need to be able
> to set the property to null for the property to be ignored. I would
> appreciate your thoughts on this.
>
> Benny
>
>
> On Tue, Oct 13, 2009 at 12:48 PM, Lance Java wrote:
>
>> The java beans spec only states that "is" can be used for boolean, it does
>> not mention java.lang.Boolean.
>>
>>
>> https://cds.sun.com/is-bin/INTERSHOP.enfinity/WFS/CDS-CDS_Developer-Site/en_US/-/USD/viewproductdetail-start?productref=7224-javabeans-1.01-fr-spec-oth-js...@cds-cds_developer
>> 2009/10/13Benny
>>  Law <
>> benny.mk@gmail.com>
>>
>> > Hi all,
>> >
>> > I just came across something that seems odd to me: I have a User object
>> > which has a Boolean property with isMobileUser() and
>> setMobileUser(Boolean)
>> > as getter and setter. When I used ${user.mobileUser} in my template
>> (user
>> > is
>> > a page property), Tapestry complained about the expression being
>> > write-only.
>> > Apparently, it did not recognize the getter with the "is" prefix.
>> Changing
>> > the expression to ${user.isMobileUser()} fixed the problem.
>> >
>> > Can somebody confirm whether Tapestry recognizes the "is" getter prefix
>> for
>> > Boolean (not boolean) properties?
>> >
>> > Thanks,
>> >
>> > Benny Law
>> >
>>
>
>


Re: Boolean Property Expression

2009-10-13 Thread Benny Law
Thanks for your speedy response, Lance. I wish java.lang.Boolean were
included. The reason I use that instead of primitive boolean is that I also
use the User object for query by example in Hibernate, so I need to be able
to set the property to null for the property to be ignored. I would
appreciate your thoughts on this.

Benny

On Tue, Oct 13, 2009 at 12:48 PM, Lance Java wrote:

> The java beans spec only states that "is" can be used for boolean, it does
> not mention java.lang.Boolean.
>
>
> https://cds.sun.com/is-bin/INTERSHOP.enfinity/WFS/CDS-CDS_Developer-Site/en_US/-/USD/viewproductdetail-start?productref=7224-javabeans-1.01-fr-spec-oth-js...@cds-cds_developer
> 2009/10/13Benny
>  Law <
> benny.mk@gmail.com>
>
> > Hi all,
> >
> > I just came across something that seems odd to me: I have a User object
> > which has a Boolean property with isMobileUser() and
> setMobileUser(Boolean)
> > as getter and setter. When I used ${user.mobileUser} in my template (user
> > is
> > a page property), Tapestry complained about the expression being
> > write-only.
> > Apparently, it did not recognize the getter with the "is" prefix.
> Changing
> > the expression to ${user.isMobileUser()} fixed the problem.
> >
> > Can somebody confirm whether Tapestry recognizes the "is" getter prefix
> for
> > Boolean (not boolean) properties?
> >
> > Thanks,
> >
> > Benny Law
> >
>


Re: Boolean Property Expression

2009-10-13 Thread Lance Java
The java beans spec only states that "is" can be used for boolean, it does
not mention java.lang.Boolean.

https://cds.sun.com/is-bin/INTERSHOP.enfinity/WFS/CDS-CDS_Developer-Site/en_US/-/USD/viewproductdetail-start?productref=7224-javabeans-1.01-fr-spec-oth-js...@cds-cds_developer
2009/10/13 Benny Law 

> Hi all,
>
> I just came across something that seems odd to me: I have a User object
> which has a Boolean property with isMobileUser() and setMobileUser(Boolean)
> as getter and setter. When I used ${user.mobileUser} in my template (user
> is
> a page property), Tapestry complained about the expression being
> write-only.
> Apparently, it did not recognize the getter with the "is" prefix. Changing
> the expression to ${user.isMobileUser()} fixed the problem.
>
> Can somebody confirm whether Tapestry recognizes the "is" getter prefix for
> Boolean (not boolean) properties?
>
> Thanks,
>
> Benny Law
>


Boolean Property Expression

2009-10-13 Thread Benny Law
Hi all,

I just came across something that seems odd to me: I have a User object
which has a Boolean property with isMobileUser() and setMobileUser(Boolean)
as getter and setter. When I used ${user.mobileUser} in my template (user is
a page property), Tapestry complained about the expression being write-only.
Apparently, it did not recognize the getter with the "is" prefix. Changing
the expression to ${user.isMobileUser()} fixed the problem.

Can somebody confirm whether Tapestry recognizes the "is" getter prefix for
Boolean (not boolean) properties?

Thanks,

Benny Law