|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectit.polito.elite.doseWS.kernel.AnnoRepositoryImpl
The Annotation Repository implementation.
The annotation repository stores all semantic annotations relating documents, or
specific substructures of them to ontology concepts. The repository has persistence on
a DB by istantiating a proper DBWrapper.
class AnnoRepositoryImplTest for a testing class| Constructor Summary | |
AnnoRepositoryImpl()
void constructor web-service ready |
|
| Method Summary | |
int |
addAnnotation(java.lang.String fragmentURI,
java.lang.String fragmentXpath,
java.lang.String conceptURI,
double weight,
java.lang.String author,
java.lang.String type)
Add a single semantic annotation to the annotation repository |
int |
addAnnotations(java.lang.String fragmentURI,
java.lang.String fragmentXpath,
java.util.Hashtable conceptURIandWeights,
java.lang.String author,
java.lang.String type)
Adds a series of semantic annotations corresponding to a conceptual spectra, to the annotation repository |
Spectrum |
getSpectrum(java.lang.String fragmentURI,
java.lang.String fragmentXPath)
|
static void |
initAnnoRepository(java.lang.String endpoint,
java.lang.String server,
java.lang.String dbDriver,
java.lang.String dbURI,
java.lang.String dbUser,
java.lang.String dbPassword)
The static initialization method for the annotation repository, sets all parameters required by the repository during the runtime phase |
static boolean |
isReady()
Flag for checking if the service has been correctly initialized |
int |
remove(java.lang.String uri,
java.lang.String xPath,
java.lang.String author)
Removes a semantic annotation from the repository |
java.util.Vector |
reverseSearch(java.lang.String fragmentURI,
java.lang.String fragmentXPath)
|
java.util.Vector |
searchByTopic(java.util.Vector topicURIs,
java.util.Vector authors,
java.lang.String type,
double strict)
|
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public AnnoRepositoryImpl()
| Method Detail |
public static void initAnnoRepository(java.lang.String endpoint,
java.lang.String server,
java.lang.String dbDriver,
java.lang.String dbURI,
java.lang.String dbUser,
java.lang.String dbPassword)
throws java.lang.Exception
endpoint - the endpoint of the Expander Web Serviceserver - the server onto which the Expander runsdbDriver - the db driver that should be used by the internal DBWrapperdbURI - the uri of the DB serverdbUser - the username for accessing the dbdbPassword - the password for the db, if required
java.lang.Exception - The error that caused the initialization failurepublic static boolean isReady()
public int remove(java.lang.String uri,
java.lang.String xPath,
java.lang.String author)
throws java.lang.Exception
remove in interface AnnoRepositoryuri - the uri of the document for which annotations should be removedxPath - the xPath of the specific substructure for which annotations must be removedauthor - the author of the annotations
java.lang.ExceptionAnnoRepository.remove(java.lang.String, java.lang.String, java.lang.String)
public int addAnnotations(java.lang.String fragmentURI,
java.lang.String fragmentXpath,
java.util.Hashtable conceptURIandWeights,
java.lang.String author,
java.lang.String type)
throws java.lang.Exception
addAnnotations in interface AnnoRepositoryfragmentURI - the URI of the document for which annotations should be added in the repositoryconceptURIandWeights - the Hashtable containing the concepts and their relative weights that compare into semantic annotations
to be storedauthor - the men or device that produced the annotationstype - the type of annotations
java.lang.ExceptionAnnoRepository.addAnnotations(java.lang.String, java.lang.String, java.util.Hashtable, java.lang.String, java.lang.String)
public int addAnnotation(java.lang.String fragmentURI,
java.lang.String fragmentXpath,
java.lang.String conceptURI,
double weight,
java.lang.String author,
java.lang.String type)
throws java.lang.Exception
addAnnotation in interface AnnoRepositoryfragmentURI - the URI of the document for which the annotation should be added in the repositoryconceptURI - the URI of the concept to which the annotation is referredweight - the weight value associated to the annotationauthor - the men or device that produced the annotationtype - the type of the annotation
java.lang.ExceptionAnnoRepository.addAnnotation(java.lang.String, java.lang.String, java.lang.String, double, java.lang.String, java.lang.String)
public java.util.Vector searchByTopic(java.util.Vector topicURIs,
java.util.Vector authors,
java.lang.String type,
double strict)
searchByTopic in interface AnnoRepository
public java.util.Vector reverseSearch(java.lang.String fragmentURI,
java.lang.String fragmentXPath)
reverseSearch in interface AnnoRepository
public Spectrum getSpectrum(java.lang.String fragmentURI,
java.lang.String fragmentXPath)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||