title: Make property in parent object visible to any of its contained objects
body: <p>I have a class <code>CalculationManager</code> which is instantiated by a <code>BackgroundWorker</code> and as such has a <code>CancellationRequested</code> property.</p>
  
  <p>This <code>CalculationManager</code> has an <code>Execute()</code> method which instantiates some different <code>Calculation</code> private classes with their own <code>Execute()</code> methods which by their turn might or might not instantiate some <code>SubCalculation</code> private classes, in sort of a "work breakdown structure" fashion where each subclass implements a part of a sequential calculation.</p>
  
  <p>What I need to do is to make every of these classes to check, inside the loops of their <code>Execute()</code> methods (which are different from one another) if some "global" <code>CancellationRequested</code> has been set to true. I put "global" in quotes because this property would be in the scope of the topmost <code>CalculationManager</code> class.</p>
  
  <p>So, question is:</p>
  
  <blockquote>
    <p>How can I make a property in a class visible to every (possibly nested) of its children?</p>
  </blockquote>
  
  <p>or put down another way:</p>
  
  <blockquote>
    <p>How can I make a class check for a property in the "root object" of its parent hierarchy? (well, not quite, since <code>CalculationManager</code> will also have a parent, but you got the general idea.</p>
  </blockquote>
  
  <p>I would like to use some sort of <code>AttachedProperty</code>, but these classes are domain objects inside a class library, having nothing to do with WPF or XAML and such.</p>