All files / src/models DelayedClause.js

0% Statements 0/15
100% Branches 0/0
0% Functions 0/4
0% Lines 0/15
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27                                                     
const Clause = require( './Clause' );
 
function DelayedClause( { getFn } ) {
  this.type = 'DELAYED';
  this.get = getFn;
  var _this = this;
 
  _this.instrument = function instrumentDelayed( x ) {
    var Clause = getFn();
    return Clause.instrument( x );
  };
 
  _this.instrumentConformed = function instrumentConformedDelayed( x ) {
    var Clause = getFn();
    return Clause.instrumentConformed( x );
  };
 
  _this.conform = function conformDelayed( x ) {
    var Clause = getFn();
    return Clause.conform( x );
  };
}
 
DelayedClause.prototype = Object.create( Clause.prototype );
 
module.exports = DelayedClause;