function_classCallCheck(instance,Constructor){if(!(instanceinstanceofConstructor)){thrownewTypeError("Cannot call a class as a function");}}
function_possibleConstructorReturn(self,call){if(!self){thrownewReferenceError("this hasn't been initialised - super() hasn't been called");}returncall&&(typeofcall==="object"||typeofcall==="function") ? call : self;}
function_inherits(subClass,superClass){if(typeofsuperClass!=="function"&&superClass!==null){thrownewTypeError("Super expression must either be null or a function, not "+typeofsuperClass);}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor: {value: subClass,enumerable: false,writable: true,configurable: true}});if(superClass)Object.setPrototypeOf ? Object.setPrototypeOf(subClass,superClass) : subClass.__proto__=superClass;}
vardebug=require('debug')('json-rules-engine');
varREADY=exports.READY='READY';
varRUNNING=exports.RUNNING='RUNNING';
varFINISHED=exports.FINISHED='FINISHED';
varEngine=function(_EventEmitter){
_inherits(Engine,_EventEmitter);
/**
* Returns a new Engine instance
* @param {Rule[]} rules - array of rules to initialize with