edu.berkeley.nlp.util.IntPair Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of berkeleyparser Show documentation
Show all versions of berkeleyparser Show documentation
The Berkeley parser analyzes the grammatical structure of natural language using probabilistic context-free grammars (PCFGs).
The newest version!
package edu.berkeley.nlp.util;
import java.io.Serializable;
public class IntPair implements Serializable {
private static final long serialVersionUID = 42;
public IntPair() { }
public IntPair(int first, int second) {
this.first = first;
this.second = second;
}
public String toString() {
return first + "," + second;
}
public int hashCode() { return 29*first + second; }
public boolean equals(Object o) {
IntPair p = (IntPair)o;
return first == p.first && second == p.second;
}
public int first, second;
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy