MCPcopy Create free account
hub / github.com/microsoft/SandDance / getKeyType

Function getKeyType

docs/tests/v2/es6/js/sanddance.js:3445–3456  ·  view source on GitHub ↗
(gl, value)

Source from the content-addressed store, hash-verified

3443}
3444
3445function getKeyType(gl, value) {
3446 (0, _assert.default)(value !== undefined, 'undefined key');
3447 value = Number(value);
3448
3449 for (var key in gl) {
3450 if (gl[key] === value) {
3451 return "GL.".concat(key);
3452 }
3453 }
3454
3455 return String(value);
3456} // Public methods
3457// Resolve a WebGL enumeration name (returns itself if already a number)
3458// TODO - unify with methods above
3459

Callers 1

glKeyTypeFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected