Interface Mappings.SourceMapping

All Superinterfaces:
Iterable<IntPair>, Mappings.CoreMapping
All Known Subinterfaces:
Mapping
All Known Implementing Classes:
AbstractSourceMapping, AbstractTargetMapping, Mappings.AbstractMapping, Mappings.FiniteAbstractMapping, Mappings.IdentityMapping, Mappings.OverridingSourceMapping, Mappings.OverridingTargetMapping, Mappings.PartialMapping, Permutation
Enclosing class:
Mappings

public static interface Mappings.SourceMapping extends Mappings.CoreMapping
Mapping suitable for sourcing columns.

Properties:

  • It has a finite number of sources and targets
  • Each target has exactly one source
  • Each source has at most one target

TODO: figure out which interfaces this should extend

  • Method Details

    • getSourceCount

      int getSourceCount()
    • getSource

      int getSource(int target)
      Returns the source that a target maps to.
      Parameters:
      target - target
      Returns:
      source
      Throws:
      Mappings.NoElementException - if target is not mapped
    • getSourceOpt

      int getSourceOpt(int target)
      Returns the source that a target maps to, or -1 if it is not mapped.
    • getTargetCount

      int getTargetCount()
    • getTargetOpt

      int getTargetOpt(int source)
      Returns the target that a source maps to, or -1 if it is not mapped.
    • getMappingType

      MappingType getMappingType()
      Description copied from interface: Mappings.CoreMapping
      Returns the mapping type.
      Specified by:
      getMappingType in interface Mappings.CoreMapping
      Returns:
      Mapping type
    • isIdentity

      boolean isIdentity()
    • inverse

      Mapping inverse()