Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
13 | 2 | 4 | 0.986 | statement_sequence_member |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 13 | 364 | plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/dialogs/TextFieldNavigationHandler.java |
2 | 13 | 379 | plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/dialogs/TextFieldNavigationHandler.java |
| ||||
fSubmissions.add(new Submission(bindingService.getActiveBindingsFor(ITextEditorActionDefinitionIds.SELECT_WORD_NEXT)) { public void execute() { fIterator.setText(fNavigable.getText()); int caretPosition = fNavigable.getCaretPosition(); int newCaret = fIterator.following(caretPosition); if (newCaret != BreakIterator.DONE) { Point selection = fNavigable.getSelection(); if (caretPosition == selection.y) fNavigable.setSelection(selection.x, newCaret); else fNavigable.setSelection(selection.y, newCaret); } fIterator.setText(EMPTY_TEXT); } } ); |
| ||||
fSubmissions.add(new Submission(bindingService.getActiveBindingsFor(ITextEditorActionDefinitionIds.SELECT_WORD_PREVIOUS)) { public void execute() { fIterator.setText(fNavigable.getText()); int caretPosition = fNavigable.getCaretPosition(); int newCaret = fIterator.preceding(caretPosition); if (newCaret != BreakIterator.DONE) { Point selection = fNavigable.getSelection(); if (caretPosition == selection.x) fNavigable.setSelection(selection.y, newCaret); else fNavigable.setSelection(selection.x, newCaret); } fIterator.setText(EMPTY_TEXT); } } ); |
| |||
fSubmissions.add(new Submission(bindingService.getActiveBindingsFor(ITextEditorActionDefinitionIds. [[#variablec128a3c0]])) { public void execute() { fIterator.setText(fNavigable.getText()); int caretPosition = fNavigable.getCaretPosition(); int newCaret = fIterator. [[#variablec128a300]](caretPosition); if (newCaret != BreakIterator.DONE) { Point selection = fNavigable.getSelection(); if (caretPosition == selection. [[#variablec128a280]]) fNavigable.setSelection(selection. [[#variablec128a200]], newCaret); else fNavigable.setSelection(selection. [[#variablec128a280]], newCaret); } fIterator.setText(EMPTY_TEXT); } } ); |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
1 | 1 | [[#c128a3c0]] | SELECT_WORD_NEXT |
1 | 2 | [[#c128a3c0]] | SELECT_WORD_PREVIOUS |
2 | 1 | [[#c128a300]] | following |
2 | 2 | [[#c128a300]] | preceding |
3 | 1 | [[#c128a280]] | y |
3 | 2 | [[#c128a280]] | x |
4 | 1 | [[#c128a200]] | x |
4 | 2 | [[#c128a200]] | y |