public class SentenceUnitID extends ParagraphUnitID
Constants.CHECK_DUPLICITY_LEVEL).
This class is *IMMUTABLE*, which means that each time a method that is supposed
to change something is called, another instance is returned. The objects of this
type are pooled using SentenceUnitIDPool so that only one
instance of SentenceUnitID exists for each document.GENERAL_SEP, REVISION_SEP| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(Object obj) |
boolean |
equals(Object obj) |
static SentenceUnitID |
getInstance(long documentUID,
int documentDBRevision,
short paragraph,
short sentenceInParagraph)
This is the recommended way to create an instance.
|
short |
getSentenceInParagraph() |
int |
hashCode() |
static SentenceUnitID |
load(DataInputStream dis) |
void |
store(DataOutputStream dos) |
String |
toNiceMeString()
Returns textual representation of the unit to be printed in duplicity checking reports.
|
String |
toNiceOtherString()
Returns textual representation of the unit to be printed in duplicity checking reports.
|
String |
toString() |
getInstance, getParagraphgetDocumentDBRevision, getDocumentUID, getInstance, releasePoolspublic static SentenceUnitID getInstance(long documentUID, int documentDBRevision, short paragraph, short sentenceInParagraph)
documentUID - documentDBRevision - paragraph - sentenceInParagraph - public short getSentenceInParagraph()
public String toString()
toString in class ParagraphUnitIDpublic String toNiceMeString()
toNiceMeString in class ParagraphUnitIDpublic String toNiceOtherString()
toNiceOtherString in class ParagraphUnitIDpublic int compareTo(Object obj)
compareTo in interface ComparablecompareTo in class ParagraphUnitIDobj - public boolean equals(Object obj)
equals in class ParagraphUnitIDobj - public int hashCode()
hashCode in class ParagraphUnitIDpublic void store(DataOutputStream dos) throws IOException
store in class ParagraphUnitIDdos - IOExceptionpublic static SentenceUnitID load(DataInputStream dis) throws IOException
dis - IOExceptionCopyright © 2016 Egothor. All Rights Reserved.