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

Function dumpProperties

deps/v8/test/inspector/protocol-test.js:79–94  ·  view source on GitHub ↗
(object, prefix, firstLinePrefix)

Source from the content-addressed store, hash-verified

77 }
78
79 function dumpProperties(object, prefix, firstLinePrefix) {
80 prefix = prefix || "";
81 firstLinePrefix = firstLinePrefix || prefix;
82 lines.push(firstLinePrefix + "{");
83
84 var propertyNames = Object.keys(object);
85 propertyNames.sort();
86 for (var i = 0; i < propertyNames.length; ++i) {
87 var name = propertyNames[i];
88 if (!object.hasOwnProperty(name))
89 continue;
90 var prefixWithName = " " + prefix + name + " : ";
91 dumpValue(object[name], " " + prefix, prefixWithName);
92 }
93 lines.push(prefix + "}");
94 }
95
96 function dumpItems(object, prefix, firstLinePrefix) {
97 prefix = prefix || "";

Callers 1

dumpValueFunction · 0.70

Calls 5

dumpValueFunction · 0.85
sortMethod · 0.80
keysMethod · 0.65
pushMethod · 0.45
hasOwnPropertyMethod · 0.45

Tested by

no test coverage detected