How to dynamically return all functions in scope?
<p>I have the code below, as you can see I'm manually specifying the properties I want to return, I don't care about having private/public functions here, so I'd like a quick &amp; dynamic way to just return all functions in the scope. Is this possible? I've tried a few things but having trouble, it has to be done inside the scope otherwise it can't see the functions.</p>

<pre><code>var MyObj = {
        (function() {
            function MyFuncOne() {}
            function MyFuncTwo() {}
            return {
                MyFuncOne: MyFuncOne,
                MyFuncTwo: MyFuncTwo
            }
        })()
    }
    var MyObjTwo = {
        (function() {
            function MyFuncOne() {}
            function MyFuncTwo() {}
            return {
                MyFuncOne: MyFuncOne,
                MyFuncTwo: MyFuncTwo
            }
        })()
    }
</code></pre>

<p>Pseudo code of what I want:</p>

<pre><code>function ReturnAllProperties() { //foreach func in scope append to list }
</code></pre>

<p>then in the <code>return { ReturnAllProperties(); }</code></p>
