MCPcopy Index your code
hub / github.com/idank/explainshell / add

Method add

explainshell/web/static/js/highlight.min.js:29–30  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

27 ;return Object.assign(t,e),t};class a{constructor(){
28 this.rootNode=r(),this.stack=[this.rootNode]}get top(){
29 return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(e){
30 this.top.children.push(e)}openNode(e){const t=r({scope:e})
31 ;this.add(t),this.stack.push(t)}closeNode(){
32 if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){
33 for(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}

Callers 15

openNodeMethod · 0.95
_open_loop_schedulerFunction · 0.80
cmd_extractFunction · 0.80
load_metadataFunction · 0.80
extract_contentsFunction · 0.80
visitfunctionMethod · 0.80
_submit_nextFunction · 0.80
_addFunction · 0.80
dedup_optionsFunction · 0.80
addTextMethod · 0.80
__addSublanguageMethod · 0.80

Calls

no outgoing calls

Tested by 1

_open_loop_schedulerFunction · 0.64