title: What's the OSX equivalent of AS3s ExternalInterface
body: <p>AS3 has a method named <a href="http://scriptcult.com/subcategory_155/article_334-call-javascript-function-from-as-and-viceversa.htm" rel="nofollow">ExternalInterface</a> that allows an external process to call methods in a running as3 app and visa versa. </p>
  
  <p>I'd like to accomplish the same thing with OSX. I'm pretty new to OSX and am unsure of what's available / what my options are.</p>
  
  <p>What would be the best way to pass runtime parameters to an OSX app and return a result to the calling routine (python script, JS, .app or whatever)</p>