Created
May 1, 2012 22:08
-
-
Save renepardon/2571835 to your computer and use it in GitHub Desktop.
Where is the difference between anonymous function and private function?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function Konstruktor() | |
| { | |
| var privat = 'blubb'; | |
| function privateMethode() | |
| { | |
| alert (privat); | |
| } | |
| var anonymeMethode = function() | |
| { | |
| globaleMethode(); | |
| } | |
| globaleMethode = function() | |
| { | |
| privateMethode() | |
| } | |
| } | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment