Class NameMatchingStrategy

    • Constructor Detail

      • NameMatchingStrategy

        public NameMatchingStrategy()
    • Method Detail

      • findMatch

        protected Resource findMatch​(Resource reference,
                                     Iterable<Resource> candidates)
        Returns the first match of reference in candidates. This implementation will consider two Resources to be "matches" if they have the same name.
        Parameters:
        reference - The reference resource.
        candidates - The list of potential candidates that may match reference.
        Returns:
        The first match of reference in candidates. null if none.
      • createMatchResource

        protected static MatchResource createMatchResource​(Resource left,
                                                           Resource right,
                                                           Resource origin)
        Creates a MatchResource instance and sets all three resources of the mapping on it.
        Parameters:
        left - The left resource of this mapping.
        right - The right resource of this mapping.
        origin - The origin resource of this mapping.
        Returns:
        The create mapping.