That's a final method in EOCustomObject so the compiler is complaining when I
try to override it.
As a side note...
ERD2WPage has this method:
@Override
public void setObject(EOEnterpriseObject eo) {
setEditingContext((eo != null) ? eo.editingContext() : null);
// for SmartAssignment
d2wContext().takeValueForKey(eo, Keys.object);
/*
* Storing the EO in the D2WComponent field prevents serialization. The
* ec must be serialized before the EO. So we store the value in the
* context instead.
*/
//super.setObject(eo);
d2wContext().takeValueForKey(eo, Keys.object);
}
Do you know why it calls takeValueForKey twice on the d2wcontext? Do you think
that's on purpose or a mistake?
Johnny
On Mar 15, 2013, at 11:26 AM, Ramsey Gurley <[email protected]> wrote:
> Override __setEditingContext on your object and see what's setting it to null?
>
> On Mar 15, 2013, at 2:22 PM, Johnny Miller wrote:
>
>> Hi Ramsey,
>>
>> I tried that one for sanity's sake (to no effect) but I'm using
>> (EOEnterpriseObject) dataSource().createObject(); because it's a
>> master/select page and I already have the data source for the list.
>>
>> It only happens with new objects. If I pass in an existing EO it works.
>> And I've checked that the EO has an EC after it is initialized.
>>
>> But by the time it reaches tryToSaveChanges in ERD2WInspectPage it's
>> unassigned?
>>
>> Thanks,
>>
>> Johnny
>>
>> On Mar 15, 2013, at 10:39 AM, Ramsey Gurley <[email protected]> wrote:
>>
>>> Are you using EOUtilities.createAndInsertInstance? Don't use a constructor
>>> on an EO.
>>>
>>> One possibility, when an EO is deleted, its ec is null.
>>>
>>> Ramsey
>>>
>>> On Mar 15, 2013, at 12:16 PM, Johnny Miller wrote:
>>>
>>>> Hi,
>>>>
>>>> Run for the hills I have a new problem. In my Inspect Page's action bar I
>>>> have an action that creates a new eo. The EO is created in the top level
>>>> component that contains the embedded inspect page. I know when the EO is
>>>> created it has an editing context. But when it gets passed in somehow it
>>>> is stripped. I don't think it could be garbage collected because the top
>>>> level component still has a pointer to it.
>>>>
>>>> Any idea why an EO would get it's editing context stripped? And how to
>>>> prevent it?
>>>>
>>>> Thanks in advance,
>>>>
>>>> Aloha,
>>>> Mr. Johnny Miller
>>>> Web Development Manager
>>>> Kahalawai Media Company
>>>> Lahaina, HI 96761
>>>> tel: (808) 661-7962 | mobile: (808) 283-0791
>>>> website | e-mail
>>>>
>>>> _______________________________________________
>>>> Do not post admin requests to the list. They will be ignored.
>>>> Webobjects-dev mailing list ([email protected])
>>>> Help/Unsubscribe/Update your Subscription:
>>>> https://lists.apple.com/mailman/options/webobjects-dev/rgurley%40smarthealth.com
>>>>
>>>> This email sent to [email protected]
>>>
>>
>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [email protected]