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

Method get

projects/JavaScript/proto/fbe.js:2277–2285  ·  view source on GitHub ↗

* Get the optional value * @this {!FieldModelOptional} * @param {object=} defaults Default value, defaults is undefined * @returns {object} Result value

(defaults = undefined)

Source from the content-addressed store, hash-verified

2275 * @returns {object} Result value
2276 */
2277 get (defaults = undefined) {
2278 let fbeBegin = this.getBegin()
2279 if (fbeBegin === 0) {
2280 return defaults
2281 }
2282 let optional = this.value.get()
2283 this.getEnd(fbeBegin)
2284 return optional
2285 }
2286
2287 /**
2288 * Set the optional value (begin phase)

Callers

nothing calls this directly

Calls 3

getBeginMethod · 0.95
getEndMethod · 0.95
getMethod · 0.45

Tested by

no test coverage detected