MCPcopy Index your code
hub / github.com/nodejs/node / keyObjectTypeToString

Function keyObjectTypeToString

lib/internal/crypto/keys.js:854–864  ·  view source on GitHub ↗
(type)

Source from the content-addressed store, hash-verified

852}
853
854function keyObjectTypeToString(type) {
855 switch (type) {
856 case kKeyTypeSecret: return 'secret';
857 case kKeyTypePublic: return 'public';
858 case kKeyTypePrivate: return 'private';
859 default: {
860 const assert = require('internal/assert');
861 assert.fail('Unreachable code');
862 }
863 }
864}
865
866// The helpers below return a KeyObject's native-backed slot values,
867// populating the per-instance cache on first access via a single native

Callers 1

getKeyObjectTypeFunction · 0.85

Calls 2

requireFunction · 0.50
failMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…