View Javadoc

1   /***
2    * BSD-style license; for more info see http://pmd.sourceforge.net/license.html
3   */
4   package net.sourceforge.pmd.jaxen;
5   
6   import net.sourceforge.pmd.ast.Node;
7   
8   /***
9    * @author daniels
10   *
11   */
12  public class Attribute {
13      
14      private Node parent;
15      private String name;
16      private String value;
17  
18  	public Attribute(Node parent, String name, String value) {
19  	    this.parent = parent;
20  	    this.name = name;
21  	    this.value = value;
22  	}
23  
24      public String getName() {
25          return name;
26      }
27  
28      public String getValue() {
29          return value;
30      }
31  
32      public void setName(String name) {
33          this.name = name;
34      }
35  
36      public void setValue(String value) {
37          this.value = value;
38      }
39  
40      public Node getParent() {
41          return parent;
42      }
43  
44      public void setParent(Node parent) {
45          this.parent = parent;
46      }
47  
48      public String toString() {
49          return name + ":" + value + ":" + parent;
50      }
51  }