Class Mapping

java.lang.Object
org.incenp.obofoundry.sssom.model.Mapping

public class Mapping extends Object
  • Constructor Details

  • Method Details

    • setConfidence

      public void setConfidence(Double value)
      Sets the confidence field to a new value.
      Parameters:
      value - The new confidence value to set.
      Throws:
      IllegalArgumentException - If the value is outside of the valid range.
    • setSimilarityScore

      public void setSimilarityScore(Double value)
      Sets the similarity_score field to a new value.
      Parameters:
      value - The new similarity_score value to set.
      Throws:
      IllegalArgumentException - If the value is outside of the valid range.
    • getAuthorId

      public List<String> getAuthorId(boolean set)
      Gets the list of author_id values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of author_id values.
    • getAuthorLabel

      public List<String> getAuthorLabel(boolean set)
      Gets the list of author_label values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of author_label values.
    • getReviewerId

      public List<String> getReviewerId(boolean set)
      Gets the list of reviewer_id values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of reviewer_id values.
    • getReviewerLabel

      public List<String> getReviewerLabel(boolean set)
      Gets the list of reviewer_label values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of reviewer_label values.
    • getCreatorId

      public List<String> getCreatorId(boolean set)
      Gets the list of creator_id values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of creator_id values.
    • getCreatorLabel

      public List<String> getCreatorLabel(boolean set)
      Gets the list of creator_label values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of creator_label values.
    • getCardinalityScope

      public List<String> getCardinalityScope(boolean set)
      Gets the list of cardinality_scope values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of cardinality_scope values.
    • getCurationRule

      public List<String> getCurationRule(boolean set)
      Gets the list of curation_rule values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of curation_rule values.
    • getCurationRuleText

      public List<String> getCurationRuleText(boolean set)
      Gets the list of curation_rule_text values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of curation_rule_text values.
    • getSubjectMatchField

      public List<String> getSubjectMatchField(boolean set)
      Gets the list of subject_match_field values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of subject_match_field values.
    • getObjectMatchField

      public List<String> getObjectMatchField(boolean set)
      Gets the list of object_match_field values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of object_match_field values.
    • getMatchString

      public List<String> getMatchString(boolean set)
      Gets the list of match_string values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of match_string values.
    • getSubjectPreprocessing

      public List<String> getSubjectPreprocessing(boolean set)
      Gets the list of subject_preprocessing values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of subject_preprocessing values.
    • getObjectPreprocessing

      public List<String> getObjectPreprocessing(boolean set)
      Gets the list of object_preprocessing values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of object_preprocessing values.
    • getSeeAlso

      public List<String> getSeeAlso(boolean set)
      Gets the list of see_also values, optionally initializing the list if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty list if it happens to be null.
      Returns:
      The list of see_also values.
    • getExtensions

      public Map<String,ExtensionValue> getExtensions(boolean set)
      Gets the map of extension values, optionally initializing the map if needed.
      Parameters:
      set - If true, the underlying field will be initialized to an empty map if it happens to be null.
      Returns:
      The map of extension values.
    • isUnmapped

      public boolean isUnmapped()
      Indicates whether this mapping represents a "missing" mapping.

      A missing mapping is a mapping where the subject_id or the object_id (or both) is the special value sssom:NoTermFound, and indicates that an entity in one domain could not be mapped to any entity in another domain.

      Returns:
      True if the mapping is a missing mapping, false otherwise.
    • hasUnmappedSubject

      public boolean hasUnmappedSubject()
      Indicates whether the object of this mapping is not mapped to any entity on the subject side.
      Returns:
      True if the subject of this mapping is sssom:NoTermFound, false otherwise.
    • hasUnmappedObject

      public boolean hasUnmappedObject()
      Indicates whether the subject of this mapping is not mapped to any entity on the object side.
      Returns:
      True if the object of this mapping is sssom:NoTermFound, false otherwise.
    • isLiteral

      public boolean isLiteral()
      Indicates whether this mapping represents a "literal" mapping.

      A literal mapping is a mapping where either the subject or the object (or both) is a literal, as indicated by the subject_type or object_type slot being set to EntityType.RDFS_LITERAL.

      Returns:
      True if the mapping is a literal mapping, false otherwise.
    • invert

      public Mapping invert(String predicate)
      Creates an inverted version of this mapping with an explicit predicate.
      Parameters:
      predicate - The predicate to use for the new mapping.
      Returns:
      A new mapping that is the inverse of this one, or null if the specified predicate is itself null.
    • toSExpr

      public String toSExpr()
      Creates a canonical S-expression representing this mapping.
      Returns:
      A String uniquely representing this mapping, as a canonical S-expression.
    • invert

      public Mapping invert()
      Creates an inverted version of this mapping if possible.

      Inversion is possible if the predicate is one of the known "common" predicates and is invertible. To invert a mapping with an arbitrary predicate, use invert(String).

      Returns:
      A new mapping that is the inverse of this one, or null if inversion is not possible.
    • getSemanticSimilarityScore

      @Deprecated public Double getSemanticSimilarityScore()
      Deprecated.
      Use #getSimilarityScore() instead.
    • setSemanticSimilarityScore

      @Deprecated public void setSemanticSimilarityScore(Double value)
      Deprecated.
      Use #setSimilarityScore(Double) instead.
    • getSemanticSimilarityMeasure

      @Deprecated public String getSemanticSimilarityMeasure()
      Deprecated.
      Use #getSimilarityMeasure() instead.
    • setSemanticSimilarityMeasure

      @Deprecated public void setSemanticSimilarityMeasure(String value)
      Deprecated.
      Use #setSimilarityMeasure(String) instead.
    • builder

      public static Mapping.MappingBuilder builder()
    • toBuilder

      public Mapping.MappingBuilder toBuilder()
    • getRecordId

      public String getRecordId()
    • getSubjectId

      public String getSubjectId()
    • getSubjectLabel

      public String getSubjectLabel()
    • getSubjectCategory

      public String getSubjectCategory()
    • getPredicateId

      public String getPredicateId()
    • getPredicateLabel

      public String getPredicateLabel()
    • getPredicateModifier

      public PredicateModifier getPredicateModifier()
    • getObjectId

      public String getObjectId()
    • getObjectLabel

      public String getObjectLabel()
    • getObjectCategory

      public String getObjectCategory()
    • getMappingJustification

      public String getMappingJustification()
    • getAuthorId

      public List<String> getAuthorId()
    • getAuthorLabel

      public List<String> getAuthorLabel()
    • getReviewerId

      public List<String> getReviewerId()
    • getReviewerLabel

      public List<String> getReviewerLabel()
    • getCreatorId

      public List<String> getCreatorId()
    • getCreatorLabel

      public List<String> getCreatorLabel()
    • getLicense

      public String getLicense()
    • getSubjectType

      public EntityType getSubjectType()
    • getSubjectSource

      public String getSubjectSource()
    • getSubjectSourceVersion

      public String getSubjectSourceVersion()
    • getObjectType

      public EntityType getObjectType()
    • getObjectSource

      public String getObjectSource()
    • getObjectSourceVersion

      public String getObjectSourceVersion()
    • getPredicateType

      public EntityType getPredicateType()
    • getMappingProvider

      public String getMappingProvider()
    • getMappingSource

      public String getMappingSource()
    • getMappingCardinality

      public MappingCardinality getMappingCardinality()
    • getCardinalityScope

      public List<String> getCardinalityScope()
    • getMappingTool

      public String getMappingTool()
    • getMappingToolId

      public String getMappingToolId()
    • getMappingToolVersion

      public String getMappingToolVersion()
    • getMappingDate

      public LocalDate getMappingDate()
    • getPublicationDate

      public LocalDate getPublicationDate()
    • getConfidence

      public Double getConfidence()
    • getCurationRule

      public List<String> getCurationRule()
    • getCurationRuleText

      public List<String> getCurationRuleText()
    • getSubjectMatchField

      public List<String> getSubjectMatchField()
    • getObjectMatchField

      public List<String> getObjectMatchField()
    • getMatchString

      public List<String> getMatchString()
    • getSubjectPreprocessing

      public List<String> getSubjectPreprocessing()
    • getObjectPreprocessing

      public List<String> getObjectPreprocessing()
    • getSimilarityScore

      public Double getSimilarityScore()
    • getSimilarityMeasure

      public String getSimilarityMeasure()
    • getSeeAlso

      public List<String> getSeeAlso()
    • getIssueTrackerItem

      public String getIssueTrackerItem()
    • getOther

      public String getOther()
    • getComment

      public String getComment()
    • getExtensions

      public Map<String,ExtensionValue> getExtensions()
    • setRecordId

      public void setRecordId(String recordId)
    • setSubjectId

      public void setSubjectId(String subjectId)
    • setSubjectLabel

      public void setSubjectLabel(String subjectLabel)
    • setSubjectCategory

      public void setSubjectCategory(String subjectCategory)
    • setPredicateId

      public void setPredicateId(String predicateId)
    • setPredicateLabel

      public void setPredicateLabel(String predicateLabel)
    • setPredicateModifier

      public void setPredicateModifier(PredicateModifier predicateModifier)
    • setObjectId

      public void setObjectId(String objectId)
    • setObjectLabel

      public void setObjectLabel(String objectLabel)
    • setObjectCategory

      public void setObjectCategory(String objectCategory)
    • setMappingJustification

      public void setMappingJustification(String mappingJustification)
    • setAuthorId

      public void setAuthorId(List<String> authorId)
    • setAuthorLabel

      public void setAuthorLabel(List<String> authorLabel)
    • setReviewerId

      public void setReviewerId(List<String> reviewerId)
    • setReviewerLabel

      public void setReviewerLabel(List<String> reviewerLabel)
    • setCreatorId

      public void setCreatorId(List<String> creatorId)
    • setCreatorLabel

      public void setCreatorLabel(List<String> creatorLabel)
    • setLicense

      public void setLicense(String license)
    • setSubjectType

      public void setSubjectType(EntityType subjectType)
    • setSubjectSource

      public void setSubjectSource(String subjectSource)
    • setSubjectSourceVersion

      public void setSubjectSourceVersion(String subjectSourceVersion)
    • setObjectType

      public void setObjectType(EntityType objectType)
    • setObjectSource

      public void setObjectSource(String objectSource)
    • setObjectSourceVersion

      public void setObjectSourceVersion(String objectSourceVersion)
    • setPredicateType

      public void setPredicateType(EntityType predicateType)
    • setMappingProvider

      public void setMappingProvider(String mappingProvider)
    • setMappingSource

      public void setMappingSource(String mappingSource)
    • setMappingCardinality

      public void setMappingCardinality(MappingCardinality mappingCardinality)
    • setCardinalityScope

      public void setCardinalityScope(List<String> cardinalityScope)
    • setMappingTool

      public void setMappingTool(String mappingTool)
    • setMappingToolId

      public void setMappingToolId(String mappingToolId)
    • setMappingToolVersion

      public void setMappingToolVersion(String mappingToolVersion)
    • setMappingDate

      public void setMappingDate(LocalDate mappingDate)
    • setPublicationDate

      public void setPublicationDate(LocalDate publicationDate)
    • setCurationRule

      public void setCurationRule(List<String> curationRule)
    • setCurationRuleText

      public void setCurationRuleText(List<String> curationRuleText)
    • setSubjectMatchField

      public void setSubjectMatchField(List<String> subjectMatchField)
    • setObjectMatchField

      public void setObjectMatchField(List<String> objectMatchField)
    • setMatchString

      public void setMatchString(List<String> matchString)
    • setSubjectPreprocessing

      public void setSubjectPreprocessing(List<String> subjectPreprocessing)
    • setObjectPreprocessing

      public void setObjectPreprocessing(List<String> objectPreprocessing)
    • setSimilarityMeasure

      public void setSimilarityMeasure(String similarityMeasure)
    • setSeeAlso

      public void setSeeAlso(List<String> seeAlso)
    • setIssueTrackerItem

      public void setIssueTrackerItem(String issueTrackerItem)
    • setOther

      public void setOther(String other)
    • setComment

      public void setComment(String comment)
    • setExtensions

      public void setExtensions(Map<String,ExtensionValue> extensions)
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object