eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'Diff2::HuntMcilroy':

Home

Documentation
www.exept.de
Everywhere
for:
[back]

Class: HuntMcilroy (private in Diff2

This class is only visible from within Diff2.

Inheritance:

   Object
   |
   +--Diff2
      |
      +--Diff2::HuntMcilroy

Package:
stx:libtool
Category:
Collections-Sequenceable-Diff
Owner:
Diff2
Author:
Tony Garnock-Jones <tonyg@lshift.com>

Description:


A HuntMcilroyDiff provides a longestCommonSubsequence algorithm following Hunt and McIlroy 1976 for use by the methods on GenericDiff.

J. W. Hunt and M. D. McIlroy, An algorithm for differential file comparison, Bell Telephone Laboratories CSTR #41 (1976).
http://www.cs.dartmouth.edu/~doug/

Instance Variables
    lcs:            cached longest common subsequence


[instance variables:]

[class variables:]


Related information:



Instance protocol:

accessing
o  emptyCaches

diffing
o  longestCommonSubsequence
(comment from inherited method)
The longestCommonSubsequence (LCS) algorithm is at the heart of a diff/comm algorithm.

private
o  computeEquivalenceClasses

o  findCandidateFrom: candidates forLine: file2index startingAt: lowIndex
Find the index k in the given subrange of candidates where file2index falls strictly between the file2indexes of the kth and k+1th candidates. If no such k exists, return 0.

o  mergeCandidates: candidates file1index: file1index file2indices: file2indices
optimise by leaving early if s was the end of the candidates list, since none of the subsequent file2indices will have a place to go

o  postprocessCandidateChain: candidates

o  storeCandidate: c at: r in: candidates


Private classes:

    Candidate


ST/X 7.2.0.0; WebServer 1.670 at bd0aa1f87cdd.unknown:8081; Fri, 29 Mar 2024 11:00:52 GMT