MCPcopy Create free account
hub / github.com/chronoxor/FastBinaryEncoding / send

Method send

projects/JavaScript/proto/protoex.js:7441–7457  ·  view source on GitHub ↗

* Send value * @this {!FinalSender} * @param {!object} value Value to send * @returns {!number} Sent bytes

(value)

Source from the content-addressed store, hash-verified

7439 * @returns {!number} Sent bytes
7440 */
7441 send (value) {
7442 if ((value instanceof OrderMessage) && (value.fbeType === this.OrderMessageModel.fbeType)) {
7443 return this.send_OrderMessage(value)
7444 }
7445 if ((value instanceof BalanceMessage) && (value.fbeType === this.BalanceMessageModel.fbeType)) {
7446 return this.send_BalanceMessage(value)
7447 }
7448 if ((value instanceof AccountMessage) && (value.fbeType === this.AccountMessageModel.fbeType)) {
7449 return this.send_AccountMessage(value)
7450 }
7451 let result = 0
7452 result = this._protoSender.send(value)
7453 if (result > 0) {
7454 return result
7455 }
7456 return 0
7457 }
7458
7459 /**
7460 * Send OrderMessage value

Callers

nothing calls this directly

Calls 4

send_OrderMessageMethod · 0.95
send_BalanceMessageMethod · 0.95
send_AccountMessageMethod · 0.95
sendMethod · 0.45

Tested by

no test coverage detected