You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jdo-dev@db.apache.org by Michael Bouschen <mb...@spree.de> on 2005/11/02 15:12:52 UTC

JDOQL and public static final fields

Hi,

the JDO spec allows public final static fields being used in JDOQL. 
Chapter 14.6.2 says: "Identifiers that are persistent field names or 
public final static field names are required to be supported by JDO 
implementations.".

Does this imply I can use the class name as qualifier in the field 
access, as I would do in Java? This means, are Integer.MAX_VALUE and 
com.xyz.hr.Department.MAX_DEPARTMENTS valid JDOQL expressions?

I think they are valid JDOQL expressions, what do you think?

Regards Michael
-- 
Michael Bouschen		Tech@Spree Engineering GmbH
mailto:mbo.tech@spree.de	http://www.tech.spree.de/
Tel.:++49/30/235 520-33		Buelowstr. 66			
Fax.:++49/30/2175 2012		D-10783 Berlin			


Re: JDOQL and public static final fields

Posted by Craig L Russell <Cr...@Sun.COM>.
Hi Michael,

On Nov 2, 2005, at 6:12 AM, Michael Bouschen wrote:

> Hi,
>
> the JDO spec allows public final static fields being used in JDOQL.  
> Chapter 14.6.2 says: "Identifiers that are persistent field names  
> or public final static field names are required to be supported by  
> JDO implementations.".
>
> Does this imply I can use the class name as qualifier in the field  
> access, as I would do in Java? This means, are Integer.MAX_VALUE  
> and com.xyz.hr.Department.MAX_DEPARTMENTS valid JDOQL expressions?
>
> I think they are valid JDOQL expressions, what do you think?

They are valid according to my understanding of the consensus of the  
expert group. If it's not clear, perhaps we can clarify the wording  
in the specification.

Craig


>
> Regards Michael
> -- 
> Michael Bouschen        Tech@Spree Engineering GmbH
> mailto:mbo.tech@spree.de    http://www.tech.spree.de/
> Tel.:++49/30/235 520-33        Buelowstr. 66
> Fax.:++49/30/2175 2012        D-10783 Berlin
>
>