function() { emit(this.state, this.price * this.quantity); }