aboutsummaryrefslogtreecommitdiff
path: root/node_modules/istanbul-lib-report/lib/report-base.js
blob: 96de750d65424296929f8bc40324f75db5c7ed2d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
'use strict';

// TODO: switch to class private field when targetting node.js 12
const _summarizer = Symbol('ReportBase.#summarizer');

class ReportBase {
    constructor(opts = {}) {
        this[_summarizer] = opts.summarizer;
    }

    execute(context) {
        context.getTree(this[_summarizer]).visit(this, context);
    }
}

module.exports = ReportBase;