Re: Subclassing EOEditingContext
Re: Subclassing EOEditingContext
- Subject: Re: Subclassing EOEditingContext
- From: Kieran Kelleher <email@hidden>
- Date: Mon, 2 Jul 2007 17:09:33 -0400
Call super with matching args in your constructors when subclassing
anything. For example:
public class MyEditingContext extends ERXEC {
public MyEditingContext(EOObjectStore anObjectStore) {
super(anObjectStore);
}
public MyEditingContext() {
super();
}
/** Clears the undo stack to workaround an EOF bug (courtesy of
SelfCleaningEditingContext in Practical WebObjects book. */
public void saveChanges()
{
super.saveChanges();
if ( undoManager() != null ) undoManager().removeAllActions();
}
........... blah, blah, your methods and overrides
here ..................
}
On Jul 2, 2007, at 4:52 PM, Ricardo Strausz wrote:
And how do you manage it?
simply calling to super?
can you please give me an example?
On Jul 2, 2007, at 3:33 PM, Simon McLean wrote:
We have a subclass to enable us to limit what the default editing
context can and can't do and haven't had any problems.
Simon
On 2 Jul 2007, at 21:17, Ricardo Strausz wrote:
Hola!
What is the best practice to subclass the EOEditingContext
(besides not subclassing at all)?
Some experience on that?
Dino
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40mac.com
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden