public class DpMatrix<T> extends Object
| Constructor and Description |
|---|
DpMatrix(List<T> sequenceX,
List<T> sequenceY,
DpFunction<T> p_dpFunction) |
| Modifier and Type | Method and Description |
|---|---|
List<DpMatrixCell> |
align()
Align the two sequences.
|
List<T> |
getAlignmentElementsX(int p_xFromIdx,
int p_xToIdx)
Returns a List of X sequence elements starting at p_xFromIdx (inclusive) and ending at p_xToIdx (exclusive).
|
List<T> |
getAlignmentElementsY(int p_yFromIdx,
int p_yToIdx)
Returns a List of Y sequence elements starting at p_yFromIdx (inclusive) and ending at p_yToIdx (exclusive).
|
T |
getAlignmentElementX(int p_xIdx)
Returns an element of X sequence.
|
T |
getAlignmentElementY(int p_yIdx)
Returns an element of Y sequence.
|
DpMatrixCell |
getCell(int p_xIdx,
int p_yIdx)
Return a cell of the matrix.
|
String |
toString() |
public List<DpMatrixCell> align()
public T getAlignmentElementX(int p_xIdx)
p_xIdx - index of X sequence. The index starts with 1. The rule of sum is to specify the same index as the
cell's X index, then you'll get what you want. If 0 is specified, IndexOutOfBoundsException will be
thrown.Tpublic T getAlignmentElementY(int p_yIdx)
p_yIdx - index of Y sequence. The index starts with 1. The rule of sum is to specify the same index as the
cell's Y index, then you'll get what you want. If 0 is specified, IndexOutOfBoundsException will be
thrown.Tpublic List<T> getAlignmentElementsX(int p_xFromIdx, int p_xToIdx)
p_xFromIdx - start index of X sequence (inclusive). The index starts with 1. Usually, a return value of
DpMatrixCell#getMultiMatchXIndexBegin() is specified.p_xToIdx - end index of X sequence (exclusive). The index starts with 1. Usually, a return value of
DpMatrixCell#getMultiMatchXIndexEnd() is specified.public List<T> getAlignmentElementsY(int p_yFromIdx, int p_yToIdx)
p_yFromIdx - start index of Y sequence (inclusive). The index starts with 1. Usually, a return value of
DpMatrixCell#getMultiMatchYIndexBegin() is specified.p_yToIdx - end index of Y sequence (exclusive). The index starts with 1. Usually, a return value of
DpMatrixCell#getMultiMatchYIndexEnd() is specified.public DpMatrixCell getCell(int p_xIdx, int p_yIdx)
p_xIdx - Index of X axis. The index starts with 0.p_yIdx - Index of Y axis. The index starts with 0.Copyright © 2022. All rights reserved.