public class TupleIdentifier
extends java.lang.Object
Constructor and Description |
---|
TupleIdentifier(java.lang.String filename)
Constructs a new tuple identifier given just the name of the file
the tuple belongs to -- the number will be set later.
|
TupleIdentifier(java.lang.String filename,
int number)
Constructs a new tuple given the filename it belongs to and its
number in that file.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o)
Checks two tuple identifiers for equality.
|
java.lang.String |
getFileName()
Returns the name of the file this tuple belongs to.
|
int |
getNumber()
Returns the number of this tuple in the file.
|
int |
hashCode()
Computes the hashcode of this tuple identifier.
|
void |
setNumber(int number)
Sets the number of this tuple in the file.
|
java.lang.String |
toString()
Textual representation.
|
public TupleIdentifier(java.lang.String filename)
filename
- the name of the file this tuple belongs to.public TupleIdentifier(java.lang.String filename, int number)
filename
- the filename this tuple belongs to.number
- the number of this tuple.public java.lang.String getFileName()
public int getNumber()
public void setNumber(int number)
number
- the new number of this tuple in the file.public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
o
- an object to compare this identifier to.trueif the two tuple identifiers are equal
falseotherwise.
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object