Return-Path: Delivered-To: apmail-db-jdo-dev-archive@www.apache.org Received: (qmail 60517 invoked from network); 7 Sep 2005 16:53:22 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 7 Sep 2005 16:53:22 -0000 Received: (qmail 32633 invoked by uid 500); 7 Sep 2005 16:53:22 -0000 Mailing-List: contact jdo-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: jdo-dev@db.apache.org Delivered-To: mailing list jdo-dev@db.apache.org Received: (qmail 32617 invoked by uid 99); 7 Sep 2005 16:53:22 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 Sep 2005 09:53:22 -0700 X-ASF-Spam-Status: No, hits=0.1 required=10.0 tests=HTML_40_50,HTML_MESSAGE X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [192.18.98.36] (HELO brmea-mail-4.sun.com) (192.18.98.36) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 Sep 2005 09:53:33 -0700 Received: from fe2.sun.com ([192.18.108.79]) by brmea-mail-4.sun.com (8.12.10/8.12.9) with ESMTP id j87GrITW003213 for ; Wed, 7 Sep 2005 10:53:18 -0600 (MDT) Received: from conversion-daemon.fe2.sun.com by fe2.sun.com (Sun Java System Messaging Server 6.1 HotFix 0.02 (built Aug 25 2004)) id <0IMG00M01GOT0S00@fe2.sun.com> (original mail from Craig.Russell@Sun.COM) for jdo-dev@db.apache.org; Wed, 07 Sep 2005 10:53:18 -0600 (MDT) Received: from [129.145.133.145] by fe2.sun.com (Sun Java System Messaging Server 6.1 HotFix 0.02 (built Aug 25 2004)) with ESMTPSA id <0IMG00E5PHKTHOR1@fe2.sun.com> for jdo-dev@db.apache.org; Wed, 07 Sep 2005 10:53:18 -0600 (MDT) Date: Wed, 07 Sep 2005 09:53:16 -0700 From: Craig Russell Subject: Spec clarification on pm.newInstance object id To: JDO Expert Group , jdo-dev@db.apache.org Message-id: MIME-version: 1.0 X-Mailer: Apple Mail (2.734) Content-type: multipart/signed; protocol="application/pkcs7-signature"; boundary=Apple-Mail-92--371574213; micalg=sha1 X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N --Apple-Mail-92--371574213 Content-Type: multipart/alternative; boundary=Apple-Mail-91--371574952 --Apple-Mail-91--371574952 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=WINDOWS-1252; delsp=yes; format=flowed Javadogs, I'd like to clarify the specification for the object-id for instances =20= created using pm.newInstance. Here's the original text, for context. The following method is used to create an instance of a persistence-=20 capable interface, or of a concrete or abstract class. Object newInstance(Class persistenceCapable); The parameter must be one of the following: an abstract class that is declared in the metadata using the class =20 element, or an interface that is declared in the metadata using the interface =20 element, or a concrete class that is declared in the metadata as persistence-=20 capable. In this case, there must be a public no-args constructor. The returned instance is transient, and is an =93instanceof=94 the =20 parameter. Applications might use the instance via the get and set =20 property methods and change its life cycle state exactly as if it =20 were an instance of a persistence-capable class. Here's the clarification to be added: For interfaces and classes that use a SingleFieldIdentity as the =20 object-id class, if the returned instance is subsequently made =20 persistent, the target class stored in the object-id instance is the =20 parameter of the newInstance method that created it. 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! --Apple-Mail-91--371574952 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=WINDOWS-1252 Javadogs,

I'd like to clarify the = specification for the object-id for instances created using = pm.newInstance.

Here's the original text, = for context.

<spec>
The = following method is used to create an instance of a persistence-capable = interface, or of a concrete or abstract class.
Object = newInstance(Class persistenceCapable);
The parameter must be = one of the following:
an abstract class that is declared in = the metadata using the class element, or
an interface that is = declared in the metadata using the interface element, or
a = concrete class that is declared in the metadata as persistence-capable. = In this case, there must be a public no-args constructor.
The = returned instance is transient, and is an =93instanceof=94 the = parameter. Applications might use the instance via the get and set = property methods and change its life cycle state exactly as if it were = an instance of a persistence-capable = class.
</spec>

Here's the clarification to = be added:

<proposed>
Fo= r interfaces and classes that use a SingleFieldIdentity as the object-id = class, if the returned instance is subsequently made persistent, the = target class stored in the object-id instance is the parameter of the = newInstance method that created = it.
</proposed>

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!


= --Apple-Mail-91--371574952-- --Apple-Mail-92--371574213 Content-Transfer-Encoding: base64 Content-Type: application/pkcs7-signature; name=smime.p7s Content-Disposition: attachment; filename=smime.p7s MIAGCSqGSIb3DQEHAqCAMIACAQExCzAJBgUrDgMCGgUAMIAGCSqGSIb3DQEHAQAAoIIGHjCCAtcw ggJAoAMCAQICAw3FWTANBgkqhkiG9w0BAQQFADBiMQswCQYDVQQGEwJaQTElMCMGA1UEChMcVGhh d3RlIENvbnN1bHRpbmcgKFB0eSkgTHRkLjEsMCoGA1UEAxMjVGhhd3RlIFBlcnNvbmFsIEZyZWVt YWlsIElzc3VpbmcgQ0EwHhcNMDUwMTEwMDA0MTA5WhcNMDYwMTEwMDA0MTA5WjBHMR8wHQYDVQQD ExZUaGF3dGUgRnJlZW1haWwgTWVtYmVyMSQwIgYJKoZIhvcNAQkBFhVDcmFpZy5SdXNzZWxsQFN1 bi5DT00wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDti7ZE4rO6oXKbLM02AG9WY55t udmBVL53fb3V3X5S1kvcJOk1NEMIYT/T7Ww+/hE955zvHT29+mIoNe8AW/yj1WUH8uGG2HxhwCHI UQTHmN/ioVJgjwUaYbtNMKbL/NRpnL0QWewdMJS+6IFzFyX7ADFW5cJ+UWNLvNeWAQtN0mtLildn vdOgh50i8YPvACNkCHoomGjXx0azcXbe1X3c5AgRI6e2CZe5k2lRFQFUMqkjdoMtQPoNqJ1BxH9l i4cnabl8mcT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