db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Craig Russell <Craig.Russ...@Sun.COM>
Subject Re: Questions about PC classes SFI
Date Wed, 29 Jun 2005 17:00:10 GMT
Hi,

On Jun 29, 2005, at 8:27 AM, Michelle Caisse wrote:

> Michael, Craig, Michael,
>
> Michael Watzek wrote:
>
>
>> Hi Craig,
>>
>>
>>> You will need new classes and .jdo files for single field  
>>> identity. Copy pc.mylib.PCPoint from application identity but  
>>> redefine it to use SFI and call them  
>>> pc.singlefieldidentity.PCPointSingleFieldint
>>> pc.singlefieldidentity.PCPointSingleFieldInteger
>>> pc.singlefieldidentity.PCPointSingleFieldshort
>>> pc.singlefieldidentity.PCPointSingleFieldShort
>>> pc.singlefieldidentity.PCPointSingleFieldlong
>>> pc.singlefieldidentity.PCPointSingleFieldLong
>>> pc.singlefieldidentity.PCPointSingleFieldchar
>>> pc.singlefieldidentity.PCPointSingleFieldCharacter
>>> pc.singlefieldidentity.PCPointSingleFieldbyte
>>> pc.singlefieldidentity.PCPointSingleFieldByte
>>> pc.singlefieldidentity.PCPointSingleFieldString
>>>
>>
>> The class names are not applicable on Windows systems - due to  
>> case insensitivity. I suggest to extend the class name of the pc  
>> SFI classes with wrapper types with the word "Wrapper", e.g.  
>> "PCPointSingleFieldIntegerWrapper",  
>> "PCPointSingleFieldShortWrapper", etc.
>>
>
> I suggest using the naming convention that is used in pc.fieldtypes:
> .PCPointSingleFieldPrimitiveshort
> .PCPointSingleFieldShort
> ...
>
>
>>
>> Another question: What do you mean with "... redefine ..."? Should  
>> I just copy the PC point class 11 times and adapt the type of the  
>> primary key fields accordingly?
>>
>
> Yes, I believe that's what Craig meant.

That's what I meant. The alternative is to use a single class that  
has all of the types we want and redefine it using the .jdo and .orm  
metadata files.

I just looked at pc.PrimitiveTypes and it has too much in it (the Oid  
class isn't needed) but it might be used.

Whichever is easiest to do...The benefit to defining new classes is  
that we can run all of the tests with the same schema, .jdo, and .orm  
files. I don't know that a single class is any easier to implement.

Craig
>
> -- Michelle
>
>
>>
>> Regards,
>> Michael
>>
>
>
>

Craig Russell
Architect, Sun Java Enterprise System http://java.sun.com/products/jdo
408 276-5638 mailto:Craig.Russell@sun.com
P.S. A good JDO? O, Gasp!


Mime
View raw message