|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.google.enterprise.adaptor.DocId
public class DocId
Refers to a unique document in repository. It is a thin wrapper of String
that adds meaning to the String and prevents the string from being
confused with others that do not refer to documents.
You provide a DocId
to methods like DocIdPusher.pushDocIds(java.lang.Iterable
to inform the GSA about the document's existance, so that it can crawl and
index it. When the GSA requests that document's contents, Request.getDocId()
will have the same unique id as DocId
you provided.
However, just because a DocId
is provided, does not mean the value it
represents exists or ever existed. The GSA can query for documents that have
been deleted and users can query for documents that never existed.
Constructor Summary | |
---|---|
DocId(String id)
Construct an identifier based on id . |
Method Summary | |
---|---|
int |
compareTo(DocId docId)
Provides comparison for ids based on the unique id string. |
boolean |
equals(Object o)
Determines equality based on the unique id string. |
String |
getUniqueId()
Returns the string identifier provided to the constructor. |
int |
hashCode()
Generates a hash code based on the unique id string. |
String |
toString()
Generates a string useful for debugging that contains the unique id. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public DocId(String id)
id
.
id
- non-null
document identifierMethod Detail |
---|
public String getUniqueId()
public String toString()
toString
in class Object
public boolean equals(Object o)
equals
in class Object
public int hashCode()
hashCode
in class Object
public int compareTo(DocId docId)
compareTo
in interface Comparable<DocId>
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |