1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 | 'use strict';
|
11 |
|
12 | var GraphQLMultiReporter =
|
13 |
|
14 | function () {
|
15 | function GraphQLMultiReporter() {
|
16 | for (var _len = arguments.length, reporters = new Array(_len), _key = 0; _key < _len; _key++) {
|
17 | reporters[_key] = arguments[_key];
|
18 | }
|
19 |
|
20 | this._reporters = reporters;
|
21 | }
|
22 |
|
23 | var _proto = GraphQLMultiReporter.prototype;
|
24 |
|
25 | _proto.reportMessage = function reportMessage(message) {
|
26 | this._reporters.forEach(function (reporter) {
|
27 | reporter.reportMessage(message);
|
28 | });
|
29 | };
|
30 |
|
31 | _proto.reportTime = function reportTime(name, ms) {
|
32 | this._reporters.forEach(function (reporter) {
|
33 | reporter.reportTime(name, ms);
|
34 | });
|
35 | };
|
36 |
|
37 | _proto.reportError = function reportError(caughtLocation, error) {
|
38 | this._reporters.forEach(function (reporter) {
|
39 | reporter.reportError(caughtLocation, error);
|
40 | });
|
41 | };
|
42 |
|
43 | return GraphQLMultiReporter;
|
44 | }();
|
45 |
|
46 | module.exports = GraphQLMultiReporter; |
\ | No newline at end of file |