|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--gov.nist.nlpir.irf.InfoObj | +--gov.nist.nlpir.irf.de.DeInteger
Representation of a integer as a DataElem.
This class will allow the use of integers as data elements and indexing
them, so that queries can take them into account. As this class is
concrete, all abstract methods of DataElem are implemented here.
Field Summary | |
(package private) static long |
serialVersionUID
serial version universal id - put here so Java does not insert one which may change due to revisions and make it impossible to deserialize earlier versions of serialized objects |
private int |
value
The value represented by this DeInteger. |
Constructor Summary | |
DeInteger(int v)
Creates a DeInteger that represents the given integer. |
|
DeInteger(java.lang.String v)
Creates a DeInteger that represents the given integer. |
Method Summary | |
void |
addHTML(java.lang.StringBuffer baseString,
int i,
boolean form)
Appends the string representation of this to the given HTML text. Caution: string is modified by this function. |
int |
compareTo(DataElem o)
Computes the difference between this and the given DeInteger. |
boolean |
equals(java.lang.Object o)
Tests whether two DeIntegers have the same value. |
boolean |
exactMatch(DataElem de)
Compares the values of this and the given DeInteger and sets the result. |
java.util.Vector |
getIndexingFeatures(ProxyDocument source,
IndexingModalities im,
DataElem field)
Gets the (actually unique) indexing feature of this DeInteger. |
int |
getValue()
Returns the value of the represented integer |
java.lang.String |
getValueAsString()
Returns a string representation of the integer |
int |
hashCode()
Redefines the default Object.hashCode(). |
void |
HTML_ShowDoc(java.lang.StringBuffer baseString)
Appends a string representation of this to the given string. |
float |
match(DataElem de)
Computes the matching score between this and the given DeInteger. |
void |
present()
Prints the value of the represented integer. |
void |
presentBrief()
Exactly the same thing as present(): prints the value. |
void |
setValue(int v)
Sets the value of the represented integer |
java.lang.String |
toString()
Returns a string representation of the integer |
Methods inherited from class java.lang.Object |
|
Field Detail |
static final long serialVersionUID
private int value
Constructor Detail |
public DeInteger(int v)
v
- the value of the represented integer.public DeInteger(java.lang.String v)
v
- the value of the integer as a string.Method Detail |
public final int getValue()
public final void setValue(int v)
v
- the new value of the represented integer.public void present()
public void presentBrief()
public final java.lang.String getValueAsString()
public final java.lang.String toString()
public java.util.Vector getIndexingFeatures(ProxyDocument source, IndexingModalities im, DataElem field)
source
- the Document from which the integer was read.im
- the controling indexing modalitiesfield
- the document field from which this DE camepublic boolean exactMatch(DataElem de)
de
- the DeInteger this is compared to.public float match(DataElem de)
de
- the DeInteger this is compared to.public int compareTo(DataElem o)
o
- the DeInteger this is compared to.public boolean equals(java.lang.Object o)
compareToObj
- the DeInteger this is compared to.public final int hashCode()
Hashtable
,
Object
public void addHTML(java.lang.StringBuffer baseString, int i, boolean form)
baseString
- the text to be extended by this. Caution: string
itself is modified.i
- not used.form
- not used.public void HTML_ShowDoc(java.lang.StringBuffer baseString)
baseString
- the string to be completed.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |