MCPcopy Index your code
hub / github.com/bcoin-org/bcoin / set

Method set

lib/script/stack.js:202–212  ·  view source on GitHub ↗

* Set stack item at index. * @param {Number} index * @param {Buffer} value * @returns {Buffer}

(index, item)

Source from the content-addressed store, hash-verified

200 */
201
202 set(index, item) {
203 if (index < 0)
204 index += this.items.length;
205
206 assert(Buffer.isBuffer(item));
207 assert(index >= 0 && index <= this.items.length);
208
209 this.items[index] = item;
210
211 return this;
212 }
213
214 /**
215 * Push item onto stack.

Callers 15

setDataMethod · 0.95
setStringMethod · 0.95
setNumMethod · 0.95
setIntMethod · 0.95
setBoolMethod · 0.95
handleSocketMethod · 0.45
reserializeUndoFunction · 0.45
fromRawMethod · 0.45
addMethod · 0.45
undocoins.jsFile · 0.45
coinview.jsFile · 0.45
bcoin.jsFile · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected