Extended the builder with an index file generator for PHP class- and function-names.
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpeclipse / builder / PHPIdentifierLocation.java
diff --git a/net.sourceforge.phpeclipse/src/net/sourceforge/phpeclipse/builder/PHPIdentifierLocation.java b/net.sourceforge.phpeclipse/src/net/sourceforge/phpeclipse/builder/PHPIdentifierLocation.java
new file mode 100644 (file)
index 0000000..f3fb463
--- /dev/null
@@ -0,0 +1,60 @@
+package net.sourceforge.phpeclipse.builder;
+
+import net.sourceforge.phpeclipse.mover.obfuscator.PHPIdentifier;
+
+/**
+ * @author khartlage
+ *
+ */
+public class PHPIdentifierLocation extends PHPIdentifier {
+  private String fClassname;
+  private String fFilename;
+
+  public PHPIdentifierLocation(String identifier, int type, String filename) {
+    this(identifier, type, filename, null);
+  }
+
+       public PHPIdentifierLocation(String identifier, int type, String filename, String classname) {
+               super(identifier, type);
+               fFilename = filename;
+               fClassname = classname;
+       }
+  /* (non-Javadoc)
+   * @see java.lang.Object#equals(java.lang.Object)
+   */
+  public boolean equals(Object obj) {
+               if (!(obj instanceof PHPIdentifierLocation)) {
+                       return false;
+               }
+    return super.equals(obj)&&fFilename.equals(((PHPIdentifierLocation)obj).fFilename);
+  }
+
+  /**
+   * @return
+   */
+  public String getClassname() {
+    return fClassname;
+  }
+
+  /**
+   * @return
+   */
+  public String getFilename() {
+    return fFilename;
+  }
+
+  /**
+   * @param string
+   */
+  public void setClassname(String string) {
+    fClassname = string;
+  }
+
+  /**
+   * @param string
+   */
+  public void setFilename(String string) {
+    fFilename = string;
+  }
+
+}