Lines Matching refs:cb

95 	Document.prototype._getPages = function(options, cb){
96 if (!cb) throw 'getBuffer is an async method and needs a callback argument';
98 cb(pages);
136 Document.prototype.download = function(defaultFileName, cb) {
138 cb = defaultFileName;
161 if (typeof cb === "function") {
162 cb();
167 Document.prototype.getBase64 = function(cb, options) {
168 if (!cb) throw 'getBase64 is an async method and needs a callback argument';
170 cb(buffer.toString('base64'));
174 Document.prototype.getDataUrl = function(cb, options) {
175 if (!cb) throw 'getDataUrl is an async method and needs a callback argument';
177 cb('data:application/pdf;base64,' + buffer.toString('base64'));
181 Document.prototype.getBuffer = function(cb, options) {
182 if (!cb) throw 'getBuffer is an async method and needs a callback argument';
184 cb(buffer);
13999 TraversalTracker.prototype.startTracking = function(event, cb) {
14002 if (callbacks.indexOf(cb) < 0) {
14003 callbacks.push(cb);
14007 TraversalTracker.prototype.stopTracking = function(event, cb) {
14011 var index = callbacks.indexOf(cb);
14024 callbacks.forEach(function(cb) {
14025 cb.apply(this, args);
14030 TraversalTracker.prototype.auto = function(event, cb, innerBlock) {
14031 this.startTracking(event, cb);
14033 this.stopTracking(event, cb);
19112 function WriteReq(chunk, encoding, cb) {
19115 this.callback = cb;
19228 function writeAfterEnd(stream, state, cb) {
19233 cb(er);
19242 function validChunk(stream, state, chunk, cb) {
19251 cb(er);
19258 Writable.prototype.write = function(chunk, encoding, cb) {
19263 cb = encoding;
19272 if (!util.isFunction(cb))
19273 cb = function() {};
19276 writeAfterEnd(this, state, cb);
19277 else if (validChunk(this, state, chunk, cb)) {
19279 ret = writeOrBuffer(this, state, chunk, encoding, cb);
19318 function writeOrBuffer(stream, state, chunk, encoding, cb) {
19332 state.buffer.push(new WriteReq(chunk, encoding, cb));
19334 doWrite(stream, state, false, len, chunk, encoding, cb);
19339 function doWrite(stream, state, writev, len, chunk, encoding, cb) {
19341 state.writecb = cb;
19351 function onwriteError(stream, state, sync, er, cb) {
19355 cb(er);
19359 cb(er);
19376 var cb = state.writecb;
19381 onwriteError(stream, state, sync, er, cb);
19395 afterWrite(stream, state, finished, cb);
19398 afterWrite(stream, state, finished, cb);
19403 function afterWrite(stream, state, finished, cb) {
19407 cb();
19450 var cb = entry.callback;
19453 doWrite(stream, state, false, len, chunk, encoding, cb);
19474 Writable.prototype._write = function(chunk, encoding, cb) {
19475 cb(new Error('not implemented'));
19481 Writable.prototype.end = function(chunk, encoding, cb) {
19485 cb = chunk;
19489 cb = encoding;
19504 endWritable(this, state, cb);
19535 function endWritable(stream, state, cb) {
19538 if (cb) {
19540 process.nextTick(cb);
19542 stream.once('finish', cb);
19871 var cb = ts.writecb;
19873 if (!cb)
19882 if (cb)
19883 cb(er);
19937 Transform.prototype._transform = function(chunk, encoding, cb) {
19941 Transform.prototype._write = function(chunk, encoding, cb) {
19943 ts.writecb = cb;
20038 PassThrough.prototype._transform = function(chunk, encoding, cb) {
20039 cb(null, chunk);
20813 Zlib.prototype._transform = function(chunk, encoding, cb) {
20820 return cb(new Error('invalid input'));
20838 this._processChunk(chunk, flushFlag, cb);
20841 Zlib.prototype._processChunk = function(chunk, flushFlag, cb) {
20848 var async = typeof cb === 'function';
20943 cb();