Alignment API and Server 4.2.${version.update}

fr.inrialpes.exmo.align.impl.edoal
Class EDOALAlignment

java.lang.Object
  extended by fr.inrialpes.exmo.align.impl.BasicAlignment
      extended by fr.inrialpes.exmo.align.impl.edoal.EDOALAlignment
All Implemented Interfaces:
Cloneable, Iterable<Cell>, Alignment, Visitable

public class EDOALAlignment
extends BasicAlignment

This class is an encapsulation of BasicAlignement so that it creates the structures required by the MappingDocument within the BasicAlignment

JE 2009: Maybe ObjectAlignment could even be better


Field Summary
protected  EDOALAlignment init
           
protected  Hashtable<String,Variable> variables
           
 
Fields inherited from class fr.inrialpes.exmo.align.impl.BasicAlignment
debug, extensions, hash1, hash2, level, namespaces, onto1, onto2, time, type
 
Constructor Summary
EDOALAlignment()
           
 
Method Summary
 void accept(TypeCheckingVisitor visitor)
           
 Cell addAlignCell(EDOALCell rule)
          Cell methods
 Cell addAlignCell(Object ob1, Object ob2)
           
 Cell addAlignCell(Object ob1, Object ob2, String relation, double measure)
          Cells are created and indexed at once
 Cell addAlignCell(String id, Object ob1, Object ob2, Relation relation, double measure)
           
 Cell addAlignCell(String id, Object ob1, Object ob2, Relation relation, double measure, Extensions extensions)
          Cell methods
 Object clone()
          Generate a copy of this alignment object
 Cell createCell(String id, Object ob1, Object ob2, Relation relation, double measure)
           
 Cell getAlignCell1(Object ob)
          Cells are retrieved These primitives are deprecated.
 Cell getAlignCell2(Object ob)
          //@deprecated There is more than one cell about one object
 Set<Cell> getAlignCells1(Object ob)
          Cells are retrieved These primitives are deprecated.
 Set<Cell> getAlignCells2(Object ob)
           
private static Id getEntity(LoadedOntology<Object> o, URI u)
           
 URI getOntology1URI()
           
 URI getOntology2URI()
           
 void init(Object onto1, Object onto2)
          Initialize the alignement before using it
 void loadInit(Alignment al)
           
 Variable recordVariable(String name, Expression expr)
           
 void setOntology1(Object ontology)
           
 void setOntology2(Object ontology)
           
static EDOALAlignment toEDOALAlignment(URIAlignment al)
          convert an URI alignment into a corresponding EDOALAlignment The same could be implemented for ObjectAlignent if necessary
 URIAlignment toURIAlignment()
          This is a clone with the URI instead of Object objects This conversion will drop any correspondences using something not identified by an URI For converting to ObjectAlignment, first convert to URIAlignment and load as an ObjectAlignment The same code as for ObjectAlignment works...
 URIAlignment toURIAlignment(boolean strict)
           
 
Methods inherited from class fr.inrialpes.exmo.align.impl.BasicAlignment
accept, addCell, avgConfidence, cleanUp, compose, convertExtension, createNewAlignment, cut, cut, cut2, diff, dump, getAlignedObject1, getAlignedObject2, getAlignedRelation1, getAlignedRelation2, getAlignedStrength1, getAlignedStrength2, getArrayElements, getElements, getExtension, getExtensions, getFile1, getFile2, getLevel, getOntology1, getOntology2, getOntologyObject1, getOntologyObject2, getParameters, getType, getXNamespace, getXNamespaces, harden, ingest, init, inverse, iterator, join, maxConfidence, meet, minConfidence, nbCells, remCell, removeAlignCell, render, setExtension, setExtensions, setFile1, setFile2, setLevel, setType, setXNamespace, varianceConfidence
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

init

protected EDOALAlignment init

variables

protected Hashtable<String,Variable> variables
Constructor Detail

EDOALAlignment

public EDOALAlignment()
Method Detail

accept

public void accept(TypeCheckingVisitor visitor)
            throws AlignmentException
Throws:
AlignmentException

init

public void init(Object onto1,
                 Object onto2)
          throws AlignmentException
Description copied from interface: Alignment
Initialize the alignement before using it

Specified by:
init in interface Alignment
Overrides:
init in class BasicAlignment
Throws:
AlignmentException

loadInit

public void loadInit(Alignment al)
              throws AlignmentException
Throws:
AlignmentException

recordVariable

public Variable recordVariable(String name,
                               Expression expr)

addAlignCell

public Cell addAlignCell(EDOALCell rule)
                  throws AlignmentException
Cell methods

Throws:
AlignmentException

addAlignCell

public Cell addAlignCell(String id,
                         Object ob1,
                         Object ob2,
                         Relation relation,
                         double measure,
                         Extensions extensions)
                  throws AlignmentException
Description copied from class: BasicAlignment
Cell methods

Overrides:
addAlignCell in class BasicAlignment
Throws:
AlignmentException

addAlignCell

public Cell addAlignCell(String id,
                         Object ob1,
                         Object ob2,
                         Relation relation,
                         double measure)
                  throws AlignmentException
Overrides:
addAlignCell in class BasicAlignment
Throws:
AlignmentException

addAlignCell

public Cell addAlignCell(Object ob1,
                         Object ob2,
                         String relation,
                         double measure)
                  throws AlignmentException
Description copied from interface: Alignment
Cells are created and indexed at once

Specified by:
addAlignCell in interface Alignment
Overrides:
addAlignCell in class BasicAlignment
Throws:
AlignmentException

addAlignCell

public Cell addAlignCell(Object ob1,
                         Object ob2)
                  throws AlignmentException
Specified by:
addAlignCell in interface Alignment
Overrides:
addAlignCell in class BasicAlignment
Throws:
AlignmentException

createCell

public Cell createCell(String id,
                       Object ob1,
                       Object ob2,
                       Relation relation,
                       double measure)
                throws AlignmentException
Overrides:
createCell in class BasicAlignment
Throws:
AlignmentException

getAlignCells1

public Set<Cell> getAlignCells1(Object ob)
                         throws AlignmentException
Description copied from interface: Alignment
Cells are retrieved These primitives are deprecated. Use getAlignCells1 and getAlignCells2 instead. Reason: this applies only for 1:1 alignments Some implementations might act cleverly (retrieving the best value). Basic implementations may raise the exception

Specified by:
getAlignCells1 in interface Alignment
Overrides:
getAlignCells1 in class BasicAlignment
Throws:
AlignmentException

getAlignCells2

public Set<Cell> getAlignCells2(Object ob)
                         throws AlignmentException
Specified by:
getAlignCells2 in interface Alignment
Overrides:
getAlignCells2 in class BasicAlignment
Throws:
AlignmentException

getAlignCell1

public Cell getAlignCell1(Object ob)
                   throws AlignmentException
Description copied from interface: Alignment
Cells are retrieved These primitives are deprecated. Use getAlignCells1 and getAlignCells2 instead. Reason: this applies only for 1:1 alignments Some implementations might act cleverly (retrieving the best value). Basic implementations may raise the exception //@deprecated There is more than one cell about one object

Specified by:
getAlignCell1 in interface Alignment
Overrides:
getAlignCell1 in class BasicAlignment
Throws:
AlignmentException

getAlignCell2

public Cell getAlignCell2(Object ob)
                   throws AlignmentException
Description copied from interface: Alignment
//@deprecated There is more than one cell about one object

Specified by:
getAlignCell2 in interface Alignment
Overrides:
getAlignCell2 in class BasicAlignment
Throws:
AlignmentException

getOntology1URI

public URI getOntology1URI()
Specified by:
getOntology1URI in interface Alignment
Overrides:
getOntology1URI in class BasicAlignment

getOntology2URI

public URI getOntology2URI()
Specified by:
getOntology2URI in interface Alignment
Overrides:
getOntology2URI in class BasicAlignment

setOntology1

public void setOntology1(Object ontology)
                  throws AlignmentException
Specified by:
setOntology1 in interface Alignment
Overrides:
setOntology1 in class BasicAlignment
Throws:
AlignmentException

setOntology2

public void setOntology2(Object ontology)
                  throws AlignmentException
Specified by:
setOntology2 in interface Alignment
Overrides:
setOntology2 in class BasicAlignment
Throws:
AlignmentException

toURIAlignment

public URIAlignment toURIAlignment()
                            throws AlignmentException
This is a clone with the URI instead of Object objects This conversion will drop any correspondences using something not identified by an URI For converting to ObjectAlignment, first convert to URIAlignment and load as an ObjectAlignment The same code as for ObjectAlignment works...

Overrides:
toURIAlignment in class BasicAlignment
Throws:
AlignmentException

toURIAlignment

public URIAlignment toURIAlignment(boolean strict)
                            throws AlignmentException
Throws:
AlignmentException

toEDOALAlignment

public static EDOALAlignment toEDOALAlignment(URIAlignment al)
                                       throws AlignmentException
convert an URI alignment into a corresponding EDOALAlignment The same could be implemented for ObjectAlignent if necessary

Throws:
AlignmentException

getEntity

private static Id getEntity(LoadedOntology<Object> o,
                            URI u)
                     throws OntowrapException,
                            AlignmentException
Throws:
OntowrapException
AlignmentException

clone

public Object clone()
Generate a copy of this alignment object

Specified by:
clone in interface Alignment
Overrides:
clone in class BasicAlignment

Alignment API and Server 4.2.${version.update}

(C) INRIA & friends, 2003-${curryear}