-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathlibCtx.js
52 lines (47 loc) · 1.13 KB
/
libCtx.js
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
48
49
50
51
52
/*
* pmt.mcpe.me
*
* Copyright (C) 2015 PEMapModder
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* @author PEMapModder
*/
var contexts = [];
function Resource(type, explanation, resId){
this.type = type;
this.explain = explanation;
this.resId = resId;
}
function Context(){
this.resources = {};
}
Context.prototype.addResource = function(res){
this.resources[res.resId] = res;
};
/*
function Runnable(id, explain){
this.id = id;
this.explain = explain;
}
Runnable.prototype.getExplain = function(){
return this.explain;
};
function RunnableGroup(id, explain){
this.id = id;
this.explain = explain;
this.children = {};
}
RunnableGroup.prototype = Runnable;
RunnableGroup.prototype.getExplain = function(){
var child;
var out = this.explain + "<ol>";
for(child in this.children){
out += "<li>" + child.getExplain() + "</li>";
}
return out + "</ol>";
};
*/