package EDU.neu.ccs.demeter.tools.apstudio.graphedit; import java.awt.*; import java.io.*; import java.util.*; import EDU.neu.ccs.demeter.*; import EDU.neu.ccs.demeter.common.tg.*; import EDU.neu.ccs.demeter.*; class ClassGlob_Commalist implements java.util.Enumeration, Cloneable { protected Nonempty_ClassGlob_Commalist first; public Nonempty_ClassGlob_Commalist get_first() { return first; } public void set_first(Nonempty_ClassGlob_Commalist new_first) { first = new_first; } ClassGlob_Commalist() { super(); } public ClassGlob_Commalist(Nonempty_ClassGlob_Commalist first) { super(); set_first(first); } public static ClassGlob_Commalist parse(java.io.InputStream in) throws ParseException { return new Parser(in)._ClassGlob_Commalist(); } public static ClassGlob_Commalist parse(String s) { try { return parse(new java.io.ByteArrayInputStream(s.getBytes())); } catch (ParseException e) { throw new RuntimeException(e.toString()); } } void universal_trv0_bef(UniversalVisitor _v_) { _v_.before(this); } void universal_trv0_aft(UniversalVisitor _v_) { _v_.after(this); } void universal_trv0(UniversalVisitor _v_) { universal_trv0_bef(_v_); _v_.before_first(this, first); first.universal_trv0(_v_); _v_.after_first(this, first); universal_trv0_aft(_v_); } void toAllSubclasses_Program_trv_bef(ClassNameTranspVisitor cntv, EdgeVisitor aev) { } void toAllSubclasses_Program_trv_aft(ClassNameTranspVisitor cntv, EdgeVisitor aev) { } void toAllSubclasses_Program_trv(ClassNameTranspVisitor cntv, EdgeVisitor aev) { toAllSubclasses_Program_trv_bef(cntv, aev); first.toAllSubclasses_Program_trv(cntv, aev); toAllSubclasses_Program_trv_aft(cntv, aev); } void checkStars_ProgramBehavior_trv_bef(DummyVisitor dv) { } void checkStars_ProgramBehavior_trv_aft(DummyVisitor dv) { } void checkStars_ProgramBehavior_trv(DummyVisitor dv) { checkStars_ProgramBehavior_trv_bef(dv); first.checkStars_ProgramBehavior_trv(dv); checkStars_ProgramBehavior_trv_aft(dv); } void allSources_StrategyGraph_trv_bef(GlobVisitor __v0) { } void allSources_StrategyGraph_trv_aft(GlobVisitor __v0) { } void allSources_StrategyGraph_trv(GlobVisitor __v0) { allSources_StrategyGraph_trv_bef(__v0); first.allSources_StrategyGraph_trv(__v0); allSources_StrategyGraph_trv_aft(__v0); } void allDests_StrategyGraph_trv_bef(GlobVisitor __v0) { } void allDests_StrategyGraph_trv_aft(GlobVisitor __v0) { } void allDests_StrategyGraph_trv(GlobVisitor __v0) { allDests_StrategyGraph_trv_bef(__v0); first.allDests_StrategyGraph_trv(__v0); allDests_StrategyGraph_trv_aft(__v0); } void __trav_markReachableForwardFromSources_StrategyGraph_trv_bef(__V_StrategyGraph_markReachableForwardFromSources __v0) { } void __trav_markReachableForwardFromSources_StrategyGraph_trv_aft(__V_StrategyGraph_markReachableForwardFromSources __v0) { } void __trav_markReachableForwardFromSources_StrategyGraph_trv(__V_StrategyGraph_markReachableForwardFromSources __v0) { __trav_markReachableForwardFromSources_StrategyGraph_trv_bef(__v0); first.__trav_markReachableForwardFromSources_StrategyGraph_trv(__v0); __trav_markReachableForwardFromSources_StrategyGraph_trv_aft(__v0); } void __trav_markReachableBackwardFromTargets_StrategyGraph_trv_bef(__V_StrategyGraph_markReachableBackwardFromTargets __v0) { } void __trav_markReachableBackwardFromTargets_StrategyGraph_trv_aft(__V_StrategyGraph_markReachableBackwardFromTargets __v0) { } void __trav_markReachableBackwardFromTargets_StrategyGraph_trv(__V_StrategyGraph_markReachableBackwardFromTargets __v0) { __trav_markReachableBackwardFromTargets_StrategyGraph_trv_bef(__v0); first.__trav_markReachableBackwardFromTargets_StrategyGraph_trv(__v0); __trav_markReachableBackwardFromTargets_StrategyGraph_trv_aft(__v0); } void __trav_allSourcesAndTargetsMarked_StrategyGraph_trv_bef(__V_StrategyGraph_allSourcesAndTargetsMarked __v0) { } void __trav_allSourcesAndTargetsMarked_StrategyGraph_trv_aft(__V_StrategyGraph_allSourcesAndTargetsMarked __v0) { } void __trav_allSourcesAndTargetsMarked_StrategyGraph_trv(__V_StrategyGraph_allSourcesAndTargetsMarked __v0) { __trav_allSourcesAndTargetsMarked_StrategyGraph_trv_bef(__v0); first.__trav_allSourcesAndTargetsMarked_StrategyGraph_trv(__v0); __trav_allSourcesAndTargetsMarked_StrategyGraph_trv_aft(__v0); } void __trav_getFirst_StrategyGraph_trv_bef(__V_StrategyGraph_getFirst __v0) { } void __trav_getFirst_StrategyGraph_trv_aft(__V_StrategyGraph_getFirst __v0) { } void __trav_getFirst_StrategyGraph_trv(java.util.BitSet nodes, __V_StrategyGraph_getFirst __v0) { __trav_getFirst_StrategyGraph_trv_bef(__v0); { java.util.BitSet newnodes = new java.util.BitSet(); newnodes.set(1); newnodes.and(nodes); if (!newnodes.equals(new java.util.BitSet())) first.__trav_getFirst_StrategyGraph_trv(newnodes, __v0); } __trav_getFirst_StrategyGraph_trv_aft(__v0); } void collectSource_SGEdge_trv_bef(VecVisitor vv) { } void collectSource_SGEdge_trv_aft(VecVisitor vv) { } void collectSource_SGEdge_trv(VecVisitor vv) { collectSource_SGEdge_trv_bef(vv); first.collectSource_SGEdge_trv(vv); collectSource_SGEdge_trv_aft(vv); } void collectDest_SGEdge_trv_bef(VecVisitor vv) { } void collectDest_SGEdge_trv_aft(VecVisitor vv) { } void collectDest_SGEdge_trv(VecVisitor vv) { collectDest_SGEdge_trv_bef(vv); first.collectDest_SGEdge_trv(vv); collectDest_SGEdge_trv_aft(vv); } void allClassNames_ClassGlobSpec_trv_bef(ClassGlobVisitor v) { } void allClassNames_ClassGlobSpec_trv_aft(ClassGlobVisitor v) { } void allClassNames_ClassGlobSpec_trv(ClassGlobVisitor v) { allClassNames_ClassGlobSpec_trv_bef(v); first.allClassNames_ClassGlobSpec_trv(v); allClassNames_ClassGlobSpec_trv_aft(v); } void allGlobs_ClassGlobSpec_trv_bef(GlobVisitor v) { } void allGlobs_ClassGlobSpec_trv_aft(GlobVisitor v) { } void allGlobs_ClassGlobSpec_trv(GlobVisitor v) { allGlobs_ClassGlobSpec_trv_bef(v); first.allGlobs_ClassGlobSpec_trv(v); allGlobs_ClassGlobSpec_trv_aft(v); } private Nonempty_ClassGlob_Commalist tail; public void addElement(ClassGlob e) { checktail(); if (tail == null) { first = new Nonempty_ClassGlob_Commalist(e,null); tail = first; } else { tail.set_next(new Nonempty_ClassGlob_Commalist(e,null)); tail = tail.get_next(); } } public void push(ClassGlob e) { first = new Nonempty_ClassGlob_Commalist(e,first); } public java.util.Enumeration elements() { return new ClassGlob_Commalist(first); } public int size() { int i= 0; for (java.util.Enumeration e=elements(); e.hasMoreElements(); i++) e.nextElement(); return i; } public boolean isEmpty() { return (first == null); } public boolean hasMoreElements() { return (first != null); } public Object nextElement() { ClassGlob car = first.get_it(); first = first.get_next(); return (Object) car; } private void checktail() { if (tail == null && first != null) { tail = first; while (tail.get_next() != null) tail = tail.get_next(); } } public boolean contains(ClassGlob e) { java.util.Enumeration en = this.elements(); while (en.hasMoreElements()) if (e.equals((ClassGlob) en.nextElement())) return true; return false; } }