cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joerg Heinicke <joerg.heini...@gmx.de>
Subject Re: cvs commit: cocoon-2.1/src/blocks/woody/java/org/apache/cocoon/woody/binding RepeaterJXPathBinding.java
Date Thu, 04 Mar 2004 11:03:46 GMT
On 04.03.2004 09:31, Sylvain Wallez wrote:

>>>  changed isNullAllListElements() => isAnyListElementNotNull(): the
>>> duplicate negation at usage time breaks my brain ;-)
>>
>> This depends of the POV you see it:
>>
>> isNullAllListElements() -> This is not a negation. It check if :
>>
>> All elements on the List are null. Where is the negation?
>>
>> isAnyListElementNotNull() -> Here is a negation "Not null"  :-D

Hmm, that's true. But what I meant was the usage of 
!isNullAllListElements and ListElement != null inside the function.

What you are really testing for is the availableness/usability of the 
list for unique identification. So the function itself should not return 
true if it only contains nulls.

> Generally speaking, negative forms should be avoided, as their 
> interpretation may be difficult depending on people's linguistic 
> background. I used to work with Japanese people long time ago, and I'm 
> sure this name, even with a single negation, would be very hard for them 
> to understand.
> 
> So what about "hasNonNullElements()"?

Yes, this might be more obvious/understandable than "any" and "not" in 
my version.

Joerg

Mime
View raw message