"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.ExperienceCheckComposite = void 0;
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
/**
 * Composite check that combines multiple checks.
 *
 * Starts and stops all contained checks.
 */
var ExperienceCheckComposite = exports.ExperienceCheckComposite = /*#__PURE__*/function () {
  function ExperienceCheckComposite(checks) {
    (0, _classCallCheck2.default)(this, ExperienceCheckComposite);
    this.checks = checks;
  }
  return (0, _createClass2.default)(ExperienceCheckComposite, [{
    key: "start",
    value: function start(callback) {
      this.checks.forEach(function (check) {
        return check.start(callback);
      });
    }
  }, {
    key: "stop",
    value: function stop() {
      this.checks.forEach(function (check) {
        return check.stop();
      });
    }
  }]);
}();