// the name of the operation should really be collect_subclasses *operation* void collect_alternatives(Path_constraint_exp* c, Vertex * svertex, Vertex_List* alts) *wrapper* Cd_graph *prefix* (@ adjacencies->collect_alternatives(c, svertex, alts); @) *wrapper* Adjacency_Nlist *prefix* (@ Adjacency_list_iterator next(*this); Adjacency* each; while (each = next()) { Vertex_list_iterator nextsuper(*each->get_superclasses()); Vertex* eachsuper; while (eachsuper = nextsuper()) if (eachsuper->equal(svertex)) break; if (eachsuper) { if (c == NULL || !c->isXInhEdgeInTheList(each->get_source(), svertex)) { alts->append(each->get_source()); this->collect_alternatives(c,each->get_source(),alts); } } } @) *operation* void collect_alternatives(Path_constraint_exp* c, Vertex* svertex, Vertex_List* alts, Adjacency_Nlist* adjs) *wrapper* Neighbors *prefix* (@ @) *wrapper* Neighbors_wc *prefix* (@ @) *wrapper* Alternat_ns *prefix* (@ if (alternat_ns) alternat_ns->collect_alternatives(c, svertex, alts, adjs); @) *wrapper* Term_Barlist *prefix* (@ Term_list_iterator next(*this); Term* each; while (each = next()) if (c == NULL || !c->isXInhEdgeInTheList(each->get_vertex(), svertex)) { alts->append(each->get_vertex()); adjs->collect_alternatives(c, each->get_vertex(), alts); } @)