Events in an interface?

J

Jon Davis

Nevermind, apparently they can.

/// <summary>
/// When implemented, this should call SaveConfig() on the owner plop.
/// </summary>
void SaveConfig();

/// <summary>
/// When implemented, triggered when the config has been saved.
/// </summary>
event EventHandler ConfigSaved;

bool CloseOnSave {
get;
}


Jon
 
H

Heinrich Gantenbein

Yes, you can:

event EventType EventName

EventType is the delegate type for the event.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top