public class COSObjectKey extends java.lang.Object implements java.lang.Comparable<COSObjectKey>
Modifier and Type | Field and Description |
---|---|
private int |
generation |
private long |
number |
Constructor and Description |
---|
COSObjectKey(COSObject object)
Constructor.
|
COSObjectKey(long num,
int gen)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(COSObjectKey other) |
boolean |
equals(java.lang.Object obj) |
void |
fixGeneration(int genNumber)
This will set the generation number.
|
int |
getGeneration()
This will get the generation number.
|
long |
getNumber()
This will get the objects id.
|
int |
hashCode() |
java.lang.String |
toString() |
public COSObjectKey(COSObject object)
object
- The object that this key will represent.public COSObjectKey(long num, int gen)
num
- The object number.gen
- The object generation number.public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int getGeneration()
public void fixGeneration(int genNumber)
genNumber
- the new generation number.public long getNumber()
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public int compareTo(COSObjectKey other)
compareTo
in interface java.lang.Comparable<COSObjectKey>