-
Notifications
You must be signed in to change notification settings - Fork 24
Expand file tree
/
Copy pathModule.js
More file actions
47 lines (40 loc) · 875 Bytes
/
Module.js
File metadata and controls
47 lines (40 loc) · 875 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
+(function (global, factory) {
if (typeof exports === 'undefined') {
factory(global.webduino || {});
} else {
module.exports = factory;
}
}(this, function (scope) {
'use strict';
var EventEmitter = scope.EventEmitter;
/**
* A component to be attached to a board. This is an abstract class meant to be extended.
*
* @namespace webduino
* @class Module
* @constructor
* @extends webduino.EventEmitter
*/
function Module() {
EventEmitter.call(this);
}
Module.prototype = Object.create(EventEmitter.prototype, {
constructor: {
value: Module
},
/**
* Type of the module.
*
* @attribute type
* @type {String}
* @readOnly
*/
type: {
get: function () {
return this._type;
}
}
});
scope.Module = Module;
scope.module = scope.module || {};
}));