How to know if a component/feature is deleted?

I have a class with a Component2 and Feature properties where i hold my component and feature respectively.

I delete the objects from the feature tree.

But, my properties still hold the objects.

What is the best way to check if my component and feature was deleted (or still exists)?

SolidworksApi/macros