package aspectEditor.aspectEditorUtils;
import java.util.jar.JarFile;
import java.util.*;
import java.io.*;
import edu.neu.ccs.demeter.aplib.*;
import edu.neu.ccs.demeter.*;
class PartName {
  protected Ident name;
  public Ident get_name() { return name; }
  public void set_name(Ident new_name) { name = new_name; }
  public PartName() { super(); }
  public PartName(Ident name) {
    super();
    set_name(name);
  }
  public static PartName parse(java.io.Reader in) throws ParseException { return new Parser(in)._PartName(); }
  public static PartName parse(java.io.InputStream in) throws ParseException { return new Parser(in)._PartName(); }
  public static PartName parse(String s) {
    try { return parse(new java.io.StringReader(s)); }
    catch (ParseException e) {
      throw new RuntimeException(e.toString());
    }
  }
  boolean match(String l, NameMapI N) {
    String toMatch = toString();
    return N == null ? l.equals(toMatch) : N.match(toMatch, l);
  }
  public String toString() { return name.toString(); }
  public boolean equals(Object obj) {
    return toString().equals(obj.toString());
  }
  public int hashCode() {
    return toString().hashCode();
  }
  void universal_trv0_bef(UniversalVisitor _v_) {
    ((UniversalVisitor) _v_).before(this);
  }

  void universal_trv0_aft(UniversalVisitor _v_) {
    ((UniversalVisitor) _v_).after(this);
  }

  void universal_trv0(UniversalVisitor _v_) {
    universal_trv0_bef(_v_);
    ((UniversalVisitor) _v_).before_name(this, name);
    ((UniversalVisitor) _v_).after_name(this, name);
    universal_trv0_aft(_v_);
  }

  void __trav_matchEdge_GlobSpec_trv_bef(__V_GlobSpec_matchEdge __v0) {
    ((__V_GlobSpec_matchEdge) __v0).before(this);
  }

  void __trav_matchEdge_GlobSpec_trv_aft(__V_GlobSpec_matchEdge __v0) {  }

  void __trav_matchEdge_GlobSpec_trv(__V_GlobSpec_matchEdge __v0) {
    __trav_matchEdge_GlobSpec_trv_bef(__v0);
    __trav_matchEdge_GlobSpec_trv_aft(__v0);
  }

}
