title: how do I override a setter function at runtime in actionscript?
body: <p>I have an AS class with setter and getter functions.
  I need to tweak one of this class's instances so that it's setter function will process the input before assigning it to the local variable.</p>
  
  <p>or, in a more elaborated way, what should I use instead of $$$ in the example below?</p>
  
  <pre><code>class MyClass{
      private var _legend:Array;
      function set legend(legend:Array):void{
          _legend= legend;
      }
      function get legend():Array{
          return _legend;
      }
      function someFunction():void{
          foo();
      }
  }
  var mc:MyClass = new MyClass();
  mc.someFunction = function():void{
      bar();
  }
  mc.$$$ = new function(legend:Array):void{
      _legend = process(legend);
  }
  </code></pre>