| 1 |
package com.thaiopensource.relaxng.output.xsd.basic; |
| 2 |
|
| 3 |
import com.thaiopensource.relaxng.edit.SourceLocation; |
| 4 |
|
| 5 |
public class GroupRef extends Particle { |
| 6 |
private final String name; |
| 7 |
|
| 8 |
public GroupRef(SourceLocation location, Annotation annotation, String name) { |
| 9 |
super(location, annotation); |
| 10 |
this.name = name; |
| 11 |
} |
| 12 |
|
| 13 |
public String getName() { |
| 14 |
return name; |
| 15 |
} |
| 16 |
|
| 17 |
public <T> T accept(ParticleVisitor<T> visitor) { |
| 18 |
return visitor.visitGroupRef(this); |
| 19 |
} |
| 20 |
|
| 21 |
public boolean equals(Object obj) { |
| 22 |
return super.equals(obj) && name.equals(((GroupRef)obj).name); |
| 23 |
} |
| 24 |
|
| 25 |
public int hashCode() { |
| 26 |
return super.hashCode() ^ name.hashCode(); |
| 27 |
} |
| 28 |
} |