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

Method default

deps/v8/tools/locs.py:298–309  ·  view source on GitHub ↗
(self, o)

Source from the content-addressed store, hash-verified

296
297class LocsEncoder(json.JSONEncoder):
298 def default(self, o):
299 if isinstance(o, File):
300 return {"file": o.file, "target": o.target, "loc": o.loc, "in_bytes": o.in_bytes,
301 "expanded": o.expanded, "expanded_bytes": o.expanded_bytes}
302 if isinstance(o, Group):
303 return {"name": o.name, "loc": o.loc, "in_bytes": o.in_bytes,
304 "expanded": o.expanded, "expanded_bytes": o.expanded_bytes}
305 if isinstance(o, Results):
306 return {"groups": o.groups, "units": o.units,
307 "source_dependencies": o.source_dependencies,
308 "header_dependents": o.header_dependents}
309 return json.JSONEncoder.default(self, o)
310
311
312class StatusLine:

Callers 1

mainFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected