public class MappingSet extends Object
Container for a set of Mapping
s representing the document level, kc level or property level matching between two Document
s
, KnowledgeChunk
s or properties.
KnowledgeChunk
,
Mapping
,
Document
Modifier | Constructor and Description |
---|---|
protected |
MappingSet()
Empty constructor needed for Hibernate compatibility.
|
|
MappingSet(String source,
String target,
String type,
double affinity,
String comment) |
Modifier and Type | Method and Description |
---|---|
void |
addMapping(Mapping m) |
Mapping |
addMapping(Relation r,
String source,
String target,
MappingSet matchingAxioms,
double similarity,
double confidence)
Adds a mapping to this
MappingSet . |
Double |
getAffinity() |
String |
getComment() |
Configuration |
getConf() |
Date |
getCreationDate() |
Integer |
getId() |
Set<Mapping> |
getMappings() |
Mapping |
getSimilarity(String source,
String target)
Returns the similarity between
source and target , if the
Mapping for this couple is part of this MappingSet , null
otherwise. |
Mapping |
getSimilarity(String source,
String target,
Boolean simmetric) |
String |
getSource() |
String |
getSourceConnectionString() |
String |
getTarget() |
String |
getTargetConnectionString() |
String |
getType() |
User |
getUser() |
void |
initMappingsDict() |
void |
setAffinity(Double affinity) |
void |
setComment(String comment) |
void |
setConf(Configuration conf) |
void |
setCreationDate(Date creationDate) |
void |
setId(Integer id) |
void |
setMappings(Set<Mapping> mappings) |
void |
setSource(String source) |
void |
setSourceConnectionString(String sourceConnectionString) |
void |
setTarget(String target) |
void |
setTargetConnectionString(String targetConnectionString) |
void |
setType(String type) |
void |
setUser(User user) |
protected MappingSet()
public Mapping addMapping(Relation r, String source, String target, MappingSet matchingAxioms, double similarity, double confidence)
Adds a mapping to this MappingSet
.
r
- comparison relation used to obtain a matching value (equality, synonymy, meronymy, ecc.)source
- a string representing the source element of the comparisontarget
- a string representing the target element of the comparisonsimilarity
- the result value of the comparisonconfidence
- a double value representing the "level of trust" of this mappingpublic void addMapping(Mapping m)
public void initMappingsDict()
public Mapping getSimilarity(String source, String target)
Returns the similarity between source
and target
, if the
Mapping
for this couple is part of this MappingSet
, null
otherwise.
source
- the identifier of the source element.target
- the identifier of the target element.source
and target
if such similarity exists,
null otherwise.public Integer getId()
public Date getCreationDate()
public void setCreationDate(Date creationDate)
public void setId(Integer id)
public User getUser()
public void setUser(User user)
public Configuration getConf()
public void setConf(Configuration conf)
public String getSource()
public void setSource(String source)
public String getTarget()
public void setTarget(String target)
public String getSourceConnectionString()
public void setSourceConnectionString(String sourceConnectionString)
public String getTargetConnectionString()
public void setTargetConnectionString(String targetConnectionString)
public String getComment()
public void setComment(String comment)
public String getType()
public void setType(String type)
public Double getAffinity()
public void setAffinity(Double affinity)