Hi All,
I am looking at using Cayenne with Flex. Flex provides a Data Services layer
which transforms Java object into matching JavaScript classes. As Flex
needs to get and set the object id values, I want to know if what I am doing
below is the correct pattern?
regards Malcolm Edgar
package samples.contact;
..
public class Contact extends _Contact
{
public int getContactId() {
return ((Integer) DataObjectUtils.pkForObject(this)).intValue();
}
public void setContactId(int id) {
ObjectId objectId = new ObjectId("Contact", CONTACT_ID_PK_COLUMN,
id);
setObjectId(objectId);
}
}
This archive was generated by hypermail 2.0.0 : Thu Jun 15 2006 - 21:14:45 EDT