Class ComparedFeatures<F extends org.eclipse.emf.ecore.EStructuralFeature>

java.lang.Object
com._1c.g5.v8.dt.compare.model.ComparedFeatures<F>

public class ComparedFeatures<F extends org.eclipse.emf.ecore.EStructuralFeature> extends Object
Represents a compared features for a triple of EObject's.
  • Constructor Details

    • ComparedFeatures

      public ComparedFeatures(F feature)
      Constructor. Uses the given feature for all comparison sides if needed.
      Parameters:
      feature - the compared feature, cannot be null
    • ComparedFeatures

      public ComparedFeatures(F mainFeature, F otherFeature)
      Constructor. Uses the main feature for the ComparisonSide.COMMON_ANCESTOR comparison side if needed.
      Parameters:
      mainFeature - the main compared feature, cannot be null
      otherFeature - the other compared feature, cannot be null
    • ComparedFeatures

      public ComparedFeatures(F mainFeature, F otherFeature, F commonAncestorFeature)
      Constructor.
      Parameters:
      mainFeature - the main compared feature, cannot be null
      otherFeature - the other compared feature, cannot be null
      commonAncestorFeature - the common ancestor feature, cannot be null
  • Method Details

    • getMainFeature

      public F getMainFeature()
      Returns the main compared feature.
      Returns:
      the main compared feature, never null
    • getOtherFeature

      public F getOtherFeature()
      Returns the other compared feature.
      Returns:
      the other compared feature, never null
    • getCommonAncestorFeature

      public F getCommonAncestorFeature()
      Returns the common ancestor compared feature.
      Returns:
      the common ancestor compared feature, never null
    • getFeature

      public F getFeature(ComparisonSide side)
      Returns the compared feature for the specified comparison side.
      Parameters:
      side - the side to get the compared feature for, cannot be null
      Returns:
      the compared feature, never null
    • isMany

      public boolean isMany()
      Tells whether the stored feature(s) is many, see ETypedElement.isMany().
      Returns:
      true if case of many-feature, false otherwise
    • isContainment

      public boolean isContainment()
      Tells whether the stored feature(s) is containment one(s), see EReference.isContainment().
      Returns:
      true if case of containment features, false otherwise