CartoDB-SQL-API/batch/models/query/query_base.js

28 lines
594 B
JavaScript
Raw Normal View History

2016-06-01 16:39:01 +08:00
'use strict';
var util = require('util');
var JobStateMachine = require('../job_state_machine');
2016-06-01 16:39:01 +08:00
function QueryBase(index) {
JobStateMachine.call(this);
2016-06-01 16:39:01 +08:00
this.index = index;
}
util.inherits(QueryBase, JobStateMachine);
2016-06-01 16:39:01 +08:00
module.exports = QueryBase;
// should be implemented
QueryBase.prototype.setStatus = function () {
throw new Error('Unimplemented method');
};
// should be implemented
QueryBase.prototype.getNextQuery = function () {
throw new Error('Unimplemented method');
};
QueryBase.prototype.hasNextQuery = function (job) {
return !!this.getNextQuery(job);
};