Package ghidra.program.util
Class CodeUnitLCS
- java.lang.Object
-
- generic.algorithms.LCS<CodeUnitContainer>
-
- ghidra.program.util.CodeUnitLCS
-
public class CodeUnitLCS extends LCS<CodeUnitContainer>
-
-
Constructor Summary
Constructors Constructor Description CodeUnitLCS(java.util.List<CodeUnitContainer> xList, java.util.List<CodeUnitContainer> yList)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected int
lengthOfX()
protected int
lengthOfY()
boolean
matches(CodeUnitContainer x, CodeUnitContainer y)
protected CodeUnitContainer
valueOfX(int index)
protected CodeUnitContainer
valueOfY(int index)
-
-
-
Constructor Detail
-
CodeUnitLCS
public CodeUnitLCS(java.util.List<CodeUnitContainer> xList, java.util.List<CodeUnitContainer> yList)
-
-
Method Detail
-
lengthOfX
protected int lengthOfX()
- Specified by:
lengthOfX
in classLCS<CodeUnitContainer>
- Returns:
- the length of the X sequence.
-
lengthOfY
protected int lengthOfY()
- Specified by:
lengthOfY
in classLCS<CodeUnitContainer>
- Returns:
- the length of the Y sequence.
-
matches
public boolean matches(CodeUnitContainer x, CodeUnitContainer y)
- Specified by:
matches
in classLCS<CodeUnitContainer>
- Parameters:
x
- the X-sequence element of interesty
- the Y-sequence element of interest- Returns:
- true if
x
matchesy
; false otherwise.
-
valueOfX
protected CodeUnitContainer valueOfX(int index)
- Specified by:
valueOfX
in classLCS<CodeUnitContainer>
- Parameters:
index
- the position of interest in the X sequence.- Returns:
- the value in the X sequence at
index
. Assumes 1-indexing.
-
valueOfY
protected CodeUnitContainer valueOfY(int index)
- Specified by:
valueOfY
in classLCS<CodeUnitContainer>
- Parameters:
index
- the position of interest in the Y sequence.- Returns:
- the value in the Y sequence at
index
. Assumes 1-indexing.
-
-