!7 cmodule SuffixTreeSpike > DynPrintLog { sclass Node { S text; new L children; int position; *(S *text, int *position) {} S getText() { ret text; } void setText(S text) { this.text = text; } int getPosition() { ret position; } void setPosition(int position) { this.position = position; } L getChildren() { ret children; } void setChildren(L children) { this.children = children; } S printTree(String depthIndicator) { S str = ""; S positionStr = position > -1 ? "[" + position + "]" : ""; str += depthIndicator + text + positionStr + "\n"; for (int i = 0; i < children.size(); i++) str += children.get(i).printTree(depthIndicator + "\t"); return str; } toString { ret printTree(""); } } start-thread { } }