COMPARATOR
Constructor and Description |
---|
LineFragment(int startingLine1,
int modifiedLines1,
int startingLine2,
int modifiedLines2,
TextDiffTypeEnum blockType,
TextRange range1,
TextRange range2) |
Modifier and Type | Method and Description |
---|---|
void |
addAllDescendantsTo(java.util.ArrayList<LineFragment> descendants) |
void |
adjustTypeFromChildrenTypes()
Adjusts the diff type of this line fragment based on the types of the inline child fragments.
|
java.util.Iterator<Fragment> |
getChildrenIterator() |
int |
getEndLine1() |
int |
getEndLine2() |
TextRange |
getRange(FragmentSide side) |
Fragment |
getSubfragmentAt(int offset,
FragmentSide side,
Condition<? super Fragment> condition) |
DiffString |
getText(DiffString text,
FragmentSide side) |
void |
highlight(FragmentHighlighter fragmentHighlighter) |
boolean |
isEqual() |
boolean |
isHasLineChildren() |
boolean |
isOneSide() |
void |
setChildren(java.util.ArrayList<? extends Fragment> fragments) |
Fragment |
shift(TextRange range1,
TextRange range2,
int startingLine1,
int startingLine2) |
getModifiedLines1, getModifiedLines2, getStartingLine1, getStartingLine2, getType, setType
public LineFragment(int startingLine1, int modifiedLines1, int startingLine2, int modifiedLines2, TextDiffTypeEnum blockType, TextRange range1, TextRange range2)
public TextRange getRange(FragmentSide side)
public Fragment shift(TextRange range1, TextRange range2, int startingLine1, int startingLine2)
public void adjustTypeFromChildrenTypes()
Adjusts the diff type of this line fragment based on the types of the inline child fragments.
For example, a modification in terms of line fragment may be just one inline insertion. In this case it is better to think about the whole change as of insertion.
public void highlight(FragmentHighlighter fragmentHighlighter)
public boolean isOneSide()
public boolean isEqual()
public Fragment getSubfragmentAt(int offset, FragmentSide side, Condition<? super Fragment> condition)
getSubfragmentAt
in interface Fragment
public java.util.Iterator<Fragment> getChildrenIterator()
public DiffString getText(DiffString text, FragmentSide side)
public void addAllDescendantsTo(java.util.ArrayList<LineFragment> descendants)
public void setChildren(java.util.ArrayList<? extends Fragment> fragments)
public boolean isHasLineChildren()
public int getEndLine1()
getEndLine1
in class LineBlock
public int getEndLine2()
getEndLine2
in class LineBlock