Hi Mira: your earlier message seems related to this one to Boaz. There is probably an elegant solution. -- Karl ============ sent June 11, 1998 Dear Boaz: do you have a good algorithm to simultaneously follow two strategy graphs during the same traversal? -- Karl To use strategies as guards in visitor and appc entries: sg2 guard sg1 before node code // execute code only if node is visited according to sg1 we need to solve the following abstract problem: Given two strategies sg1 and sg2 with the same source, where sg1 is a substrategy of sg2, a class graph g and an object graph o with node n which is visited following strategy sg2, determine whether n is in the scope of sg1, i.e. n is visited by the traversal determined by sg1. Note: sg1 is a substrategy of sg2 if for all class graphs g: PathSet(g,sg1) is a subset of PathSet(g,sg2). Note: in the applications the strategy sg1 is often an edge. The straight-forward approach would be to compute two traversal graphs tg(g,sg1)=t1 and tg(g,sg2)=t2 and to use both during the object traversal and to have a distinct token set for each. (t1 might not be a subgraph of t2!) We need an answer to the question: "is n in the scope of sg1" repeatedly as we traverse according to sg2. Is the algorithm much simpler if sg1 is a one edge graph?