Subscribe to event

How to check whether the code is subscribe to some solidworks event?

For example, I want to know the addon was subscribed to event DPartDocEvents_NewSelectionNotifyEventHandler, if not - then subscribe if yes - continue the program.

SolidworksApi macros