We have signal/slot mechanism in Qt and observer mechanism in VTK, and you can implement custom plugin or callback mechanisms. These are all available to be used from both C++ and Python.
Probably the most universal way (that is available from all Slicer classes) is to observe/invoke custom modified events on a MRML node.