MCPcopy Create free account
hub / github.com/Moli-X/Resources / Block

Function Block

Script/Parser.js:3169–3188  ·  view source on GitHub ↗

* @class A block of lines of a given level. * @param {int} lvl The block's level. * @private

(lvl)

Source from the content-addressed store, hash-verified

3167 * @private
3168 */
3169 function Block(lvl) {
3170 return {
3171 /* The block's parent */
3172 parent: null,
3173 /* Number of children */
3174 length: 0,
3175 /* Block's level */
3176 level: lvl,
3177 /* Lines of code to process */
3178 lines: [],
3179 /* Blocks with greater level */
3180 children : [],
3181 /* Add a block to the children collection */
3182 addChild : function(obj) {
3183 this.children.push(obj);
3184 obj.parent = this;
3185 ++this.length;
3186 }
3187 };
3188 }
3189
3190 // function to create an XMLHttpClient in a cross-browser manner
3191

Callers

nothing calls this directly

Calls 1

pushMethod · 0.45

Tested by

no test coverage detected