Created
February 27, 2010 21:29
-
-
Save creationix/316969 to your computer and use it in GitHub Desktop.
This file contains 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 nodeFactory() { | |
function toStringFactory(data) { return function toString() { | |
// TODO: Implement | |
}} | |
function compileFactory(data) { return function compile() { | |
// TODO: Implement | |
}} | |
return { | |
BaseNode: function (data) { | |
return { | |
toString: toStringFactory(data), | |
compile: compileFactory(data) | |
} | |
}, | |
ForNode: function (data) { | |
return { | |
toString: function () { | |
// Override toString | |
} | |
compile: compileFactory(data) | |
} | |
} | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment