I have some special C # events related to items selected in a tree, and then a context menu used to trigger some actions on selected items. I started creating a separate EventArgs-based class for each custom event to pack the necessary data for the event.
However, I understand that most (possibly all) of my user events will need to transmit at least a list of basic objects represented by a tree selection. Some events will also need additional data.Given this, I wonder if one of the following rules is acceptable?
Use the same EventArgs-based native class for multiple events (those who just need a list of objects to pass in). Obviously this should work, but it seems to break away from some of the recommended naming conventions used to connect event equipment.
Create a base class that completes my often needed list of objects, and then derives additional classes from it, since additional data is needed.
Maybe something else?
Currently, I have only a few special events, but you need to add more. Since I see a pattern arising regarding the data needed for each event, I would like to have a better plan before continuing.
Thanks for any advice.