Created
June 30, 2010 06:09
-
-
Save canonic-epicure/458297 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
// require.paths.unshift('/us/local/lib/jsan'); | |
require.paths.unshift('/home/nickolay/Playground/nodejs'); | |
require('Task/Joose/NodeJS'); | |
var sys = require('sys'); | |
Joose.Module('SuperStuff', { | |
// the following library is available in the path unshifted above | |
require : [ 'faye' ], | |
body : function (m) { | |
Joose.Class('WillParam', { | |
// trait : JooseX.Class.SimpleConstructor, | |
// does : SuperStuff['MyFirstParamd']({ methodsMatching : /bob/ }), | |
// does : SuperStuff['MyFirstParamd']({ methodsMatching : /^.+\$(.+)\$(WOWZERS)$/ }), | |
has : { | |
things : { is : 'rw', init : 'someText' } | |
}, | |
methods : { | |
bob : function (val) { | |
this.setThings(val); | |
} | |
} | |
}) | |
} | |
}) | |
use('SuperStuff', function () { | |
SuperStuff['myVar'] = new SuperStuff['WillParam'](); | |
sys.puts(SuperStuff['myVar'].getThings()); | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment