Excellent! Thank you Denis! that will work. Don't know why I didn't think of that.
Best rbr On May 21, 2:17 am, denism <[email protected]> wrote: > Use NVI (non-virtual interface) for such purposes. > > Base class has public method Save and protected abstract method > DoSave. > The Save method generates an event after call to DoSave (or before > DoSave or both) and then calls the DoSave. > > The DoSave is overriden in numerous child classes. > > Denis > > On May 20, 6:52 pm, rbr <[email protected]> wrote: > > > > > Hello, I am trying to create an event that gets raised every time a > > particular method is called. The method is abstract in the base. The > > implementations of this method are numerous. So, for example, here is > > some psuedo-code that shows my situation: > > > public class Base > > { > > public abstract void Save(); > > > } > > > public class Inheritor : Base > > { > > public override void Save() > > { > > //Save something > > } > > > } > > > What I am trying to accomplish is triggering an event every time a > > save method is called from any child class. Is this possible? For some > > reason I am hitting a mental block! > > > Thanks in advance!- Hide quoted text - > > - Show quoted text -
