public interface Alignment extends java.lang.Cloneable, java.lang.Iterable<Cell>, Visitable
Modifier and Type | Method and Description |
---|---|
Cell |
addAlignCell(java.lang.Object ob1,
java.lang.Object ob2) |
Cell |
addAlignCell(java.lang.Object ob1,
java.lang.Object ob2,
java.lang.String relation,
double measure)
Cells are created and indexed at once
|
java.lang.Object |
clone()
Implementation of the clone method
|
Alignment |
compose(Alignment align) |
void |
cut(double threshold) |
void |
cut(java.lang.String method,
double threshold)
Trim an alignment under a particular threshold
|
Alignment |
diff(Alignment align) |
void |
dump(org.xml.sax.ContentHandler h)
Dumps an alignment into a SAX handler
Dump should be implemented as a method generating SAX events
for a SAXHandler provided as input
|
Cell |
getAlignCell1(java.lang.Object ob)
Cells are retrieved
These primitives are deprecated.
|
Cell |
getAlignCell2(java.lang.Object ob)
//@deprecated There is more than one cell about one object
|
java.util.Set<Cell> |
getAlignCells1(java.lang.Object ob)
Cells are retrieved
These primitives are deprecated.
|
java.util.Set<Cell> |
getAlignCells2(java.lang.Object ob) |
java.lang.Object |
getAlignedObject1(java.lang.Object ob)
Each part of the cell can be queried independently.
|
java.lang.Object |
getAlignedObject2(java.lang.Object ob) |
Relation |
getAlignedRelation1(java.lang.Object ob) |
Relation |
getAlignedRelation2(java.lang.Object ob) |
double |
getAlignedStrength1(java.lang.Object ob) |
double |
getAlignedStrength2(java.lang.Object ob) |
java.util.Enumeration<Cell> |
getElements() |
java.lang.String |
getExtension(java.lang.String uri,
java.lang.String label) |
java.util.Collection<java.lang.String[]> |
getExtensions()
Extensions are a way to read and add other information (metadata)
to the alignment structure itself.
|
java.net.URI |
getFile1() |
java.net.URI |
getFile2() |
java.lang.String |
getLevel() |
java.lang.Object |
getOntology1() |
java.net.URI |
getOntology1URI() |
java.lang.Object |
getOntology2() |
java.net.URI |
getOntology2URI() |
java.lang.String |
getType() |
void |
harden(double threshold) |
void |
init(java.lang.Object onto1,
java.lang.Object onto2)
Initialize the alignement before using it
|
void |
init(java.lang.Object onto1,
java.lang.Object onto2,
java.lang.Object cache)
Initialize the alignement before using it, with some ontology caching trick
//@deprecated The OntologyCache is now internal, use init( onto1, onto2 ) instead
|
Alignment |
inverse()
Algebra of alignment manipulation operations: compose, join, meet.
|
java.util.Iterator<Cell> |
iterator() |
Alignment |
join(Alignment align) |
Alignment |
meet(Alignment align) |
int |
nbCells() |
void |
remCell(Cell c) |
void |
render(AlignmentVisitor renderer)
Exporting
The alignments are exported for other purposes.
|
void |
setExtension(java.lang.String uri,
java.lang.String label,
java.lang.String value) |
void |
setFile1(java.net.URI file)
Set the ontology used by the alignment
This URI is in fact a URL of where to fetch the ontology.
|
void |
setFile2(java.net.URI file) |
void |
setLevel(java.lang.String level)
Alignment type:
Currently defined as a String.
|
void |
setOntology1(java.lang.Object ontology) |
void |
setOntology2(java.lang.Object ontology) |
void |
setType(java.lang.String type)
Alignment type:
Currently defined a sa String.
|
void init(java.lang.Object onto1, java.lang.Object onto2) throws AlignmentException
onto1
- andonto2:
- the two ontologies alignedAlignmentException
- if cannot initializevoid init(java.lang.Object onto1, java.lang.Object onto2, java.lang.Object cache) throws AlignmentException
onto1
- andonto2:
- the two ontologies alignedcache:
- a cache where to find and store the ontologiesAlignmentException
- when cannot initialisejava.lang.Object getOntology1()
java.lang.Object getOntology2()
java.net.URI getOntology1URI() throws AlignmentException
AlignmentException
- when no URI is found (unlikely)java.net.URI getOntology2URI() throws AlignmentException
AlignmentException
- when no URI is found (unlikely)void setOntology1(java.lang.Object ontology) throws AlignmentException
AlignmentException
void setOntology2(java.lang.Object ontology) throws AlignmentException
AlignmentException
void setLevel(java.lang.String level)
level
- the level of the alignmentjava.lang.String getLevel()
void setType(java.lang.String type)
type
- the type of the alignmentjava.lang.String getType()
void setFile1(java.net.URI file)
file:
- the URI of the first ontologyvoid setFile2(java.net.URI file)
java.net.URI getFile1()
java.net.URI getFile2()
Cell addAlignCell(java.lang.Object ob1, java.lang.Object ob2, java.lang.String relation, double measure) throws AlignmentException
ob1
- the object of the first ontology in the correspondenceob2
- the object of the second ontology in the correspondencerelation
- the relation between these objectsmeasure
- the confidence measure in the correspondenceAlignmentException
- when something goes wrong (unknown objects, bad relation)Cell addAlignCell(java.lang.Object ob1, java.lang.Object ob2) throws AlignmentException
AlignmentException
void remCell(Cell c) throws AlignmentException
AlignmentException
Cell getAlignCell1(java.lang.Object ob) throws AlignmentException
ob
- the object of the first ontology from which to retrieve the correspondenceAlignmentException
- when something goes wrong
//@deprecated There is more than one cell about one objectCell getAlignCell2(java.lang.Object ob) throws AlignmentException
ob
- the object of the second ontology from which to retrieve the correspondenceAlignmentException
- when something goes wrongjava.lang.Object getAlignedObject1(java.lang.Object ob) throws AlignmentException
ob
- the object of the first ontology from which to retrieve the correspondenceAlignmentException
- when something goes wrong
//@deprecated There is more than one cell about one objectjava.lang.Object getAlignedObject2(java.lang.Object ob) throws AlignmentException
AlignmentException
Relation getAlignedRelation1(java.lang.Object ob) throws AlignmentException
AlignmentException
Relation getAlignedRelation2(java.lang.Object ob) throws AlignmentException
AlignmentException
double getAlignedStrength1(java.lang.Object ob) throws AlignmentException
AlignmentException
double getAlignedStrength2(java.lang.Object ob) throws AlignmentException
AlignmentException
java.util.Set<Cell> getAlignCells1(java.lang.Object ob) throws AlignmentException
ob
- the object of the first ontology from which to retrieve the correspondencesAlignmentException
- when something goes wrongjava.util.Set<Cell> getAlignCells2(java.lang.Object ob) throws AlignmentException
AlignmentException
java.util.Collection<java.lang.String[]> getExtensions()
java.lang.String getExtension(java.lang.String uri, java.lang.String label)
void setExtension(java.lang.String uri, java.lang.String label, java.lang.String value)
java.util.Enumeration<Cell> getElements()
java.util.Iterator<Cell> iterator()
iterator
in interface java.lang.Iterable<Cell>
int nbCells()
void cut(java.lang.String method, double threshold) throws AlignmentException
method:
- a string indicating the cutting method
- getting those cells with strength above n (hard)
- getting the n best cells (best)
- getting those cells with strength at worse n under the best (span)
- getting the n% best cells (perc)
- getting those cells with strength at worse n% of the best (prop)
- getting all cells until a gap of n (hardgap)
- getting all cells until a gap of n% of the last (propgap)threshold:
- the thresholdAlignmentException
- when something goes wrong (unknown method)void cut(double threshold) throws AlignmentException
AlignmentException
void harden(double threshold) throws AlignmentException
AlignmentException
Alignment inverse() throws AlignmentException
AlignmentException
- when something goes wrong (unlikely)Alignment diff(Alignment align) throws AlignmentException
AlignmentException
Alignment meet(Alignment align) throws AlignmentException
AlignmentException
Alignment join(Alignment align) throws AlignmentException
AlignmentException
Alignment compose(Alignment align) throws AlignmentException
AlignmentException
void dump(org.xml.sax.ContentHandler h)
h:
- a SAX content handlervoid render(AlignmentVisitor renderer) throws AlignmentException
renderer
- an AlignmentVisitor object which determines how the alignment is renderedAlignmentException
- when something goes wrong (cannot render in this format)java.lang.Object clone()
(C) INRIA & friends, 2003-2020