Q. How to traverse tree if processor receive data by querying XML storage one element at a time.
A. Reintroduce stack-discipline and use recursive algorithm as usually.
Stack need to store only variables which `recursive algorithm would use. In case of XML traverse it is
tuple of (parentIndex, childName, childIndex) which defines any XML node uniquely.
foldActor () {
stack.pop(parentIndex, childName, childIndex) // restore stack
do stuff
push((parentIndex, childName, childIndex)) // push recurse step
}
January 6, 2011
January 1, 2011
The ENSIME
One more reason to take Scala seriously is port of SLIME.
I never hacked under SLIME and it make me inferior in some way.
I tried few keystrokes today. It feels great.
I learned Scala just to grasp syntax in one paper on CPS,
today I would do it again just to hack under ENSIME.
Console 2 and maybe more terminal tabs
Console | Download Console software for free at SourceForge.net
and it will save lots of mouse clicks under Windows.
and it will save lots of mouse clicks under Windows.
(*cygwin is not mandatory*)
Subscribe to:
Posts (Atom)