Created
September 6, 2012 10:07
-
-
Save djcsdy/3654273 to your computer and use it in GitHub Desktop.
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
class Idiocy { | |
function doSomethingHatstand(o:Object) { | |
// do something preposterous | |
} | |
function doSomethingLampshade(o:Object) { | |
// do something asinine | |
} | |
public function doSomething(o:Object) { | |
this["doSomething" + o.type](o); // o.type is either "Hatstand" or "Lampshade" (or the program crashes) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment