Skip to content

Instantly share code, notes, and snippets.

@oostendo
Created May 31, 2012 17:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save oostendo/2844990 to your computer and use it in GitHub Desktop.
Save oostendo/2844990 to your computer and use it in GitHub Desktop.
(function(plugin){
var Blob,
__bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };
Blob = (function() {
function Blob(inspection) {
this.run = __bind(this.run, this);
this.inspection = inspection;
}
Blob.prototype.run = function() {
return console.log('Running blob on', this.inspection);
};
return Blob;
})();
plugin(this, {
blob: Blob
});
}).call(require('models/inspection'), require("lib/plugin"));
(function(plugin){
var Face,
__bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };
Face = (function() {
function Face(inspection) {
this.represent = __bind(this.represent, this);
this.inspection = inspection;
}
Face.prototype.represent = function() {
return "Face Detection";
};
return Face;
})();
plugin(this, {
face: Face
});
}).call(require('models/inspection'), require("lib/plugin"));
(function(plugin){
var FaceFeature,
__bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };
FaceFeature = (function() {
function FaceFeature(feature) {
this.represent = __bind(this.represent, this);
this.feature = feature;
}
FaceFeature.prototype.represent = function() {
return "Face Detected!";
};
return FaceFeature;
})();
plugin(this, {
face: FaceFeature
});
}).call(require('models/feature'), require("lib/plugin"));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment