ó ìm>c@sLdZddd„ƒYZdd d„ƒYZdefd„ƒYZeZdS( sÉ WWW: http://4suite.com/4DOM e-mail: support@4suite.com Copyright (c) 2000 Fourthought Inc, USA. All Rights Reserved. See http://4suite.com/COPYRIGHT for license and copyright information tVisitorcBseZd„ZRS(cCsd|j|jfGHdS(sLDefault behavior for the visitor is simply to print an informational messagesVisiting %s node %s N(tnodeTypetnodeNametNone(tselftnode((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pytvisits(t__name__t __module__R(((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pyR stWalkerInterfacecBs#eZd„Zd„Zd„ZRS(cCs ||_dS(N(tvisitor(RR ((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pyt__init__s cCsdS(s8Advance to the next item in order, visit, and then pauseN((R((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pytstepscCsdS(sXContinue advancing from the current position through the last leaf node without pausing.N((R((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pytruns(RRR R R (((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pyR s  tPreOrderWalkercBs#eZd„Zd„Zd„ZRS(cCs-tj||ƒg|_|jj|ƒdS(N(R R t node_stacktappend(RR t startNode((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pyR "s cCs¿d}|jj|jdƒ}|jdjƒrO|jj|jdjƒnfd}x]| r´| r´|jdj}|jd=|r™|jj|ƒqXt|jƒsXd}qXqXW||fS(s Visits the current node, and then advances to its first child, if any, else the next sibling. returns a tuple completed, ret_val completed -- flags whether or not we've traversed the entire tree ret_val -- return value from the visitor iiÿÿÿÿiN( R RRt hasChildNodesRt firstChildRt nextSiblingtlen(Rt completedtret_valtnext_sib((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pyR 's  cCs)d}x|s$|jƒ\}}q WdS(Ni(R (RRR((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pyR @s (RRR R R (((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pyR!s  N(((t__doc__RR RtWalker(((sE/opt/freeware/lib/python2.7/site-packages/_xmlplus/dom/ext/Visitor.pyt s'