Composite composite = new Composite(parent, SWT.NONE);
composite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
{
GridLayout layout = new GridLayout(2, false);
layout.marginLeft = -5;
layout.marginRight = -5;
layout.marginTop = -5;
layout.marginBottom = -5;
composite.setLayout(layout);
Composite composite = new Composite(parent, SWT.NONE);
composite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
{
GridLayout layout = new GridLayout();
layout.marginLeft = -5;
layout.marginRight = -5;
layout.marginTop = -5;
layout.marginBottom = -5;
composite.setLayout(layout);
Clone fragments detected by clone detection tool
File path: /emf-2.4.1/src/org/eclipse/emf/common/ui/dialogs/WorkspaceResourceDialog.java
|
|
File path: /emf-2.4.1/src/org/eclipse/emf/exporter/ui/contribution/base/ModelExporterOptionsPage.java
|
Method name: void createFileControl(Composite)
|
|
Method name: void createSaveSettingsControl(Composite)
|
Number of AST nodes: 8
|
|
Number of AST nodes: 8
|
|
1 | Composite composite = new Composite(parent, SWT.NONE);↵ | | 1 | Composite composite = new Composite(parent, SWT.NONE);↵
|
2 | composite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));↵ | | 2 | composite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));↵
|
3 | {↵ | | 3 | {↵
|
4 | GridLayout layout = new GridLayout(2, false);↵ | | 4 | GridLayout layout = new GridLayout();↵
|
5 | layout.marginLeft = -5;↵ | | 5 | layout.marginLeft = -5;↵
|
6 | layout.marginRight = -5;↵ | | 6 | layout.marginRight = -5;↵
|
7 | layout.marginTop = -5;↵ | | 7 | layout.marginTop = -5;↵
|
8 | layout.marginBottom = -5;↵ | | 8 | layout.marginBottom = -5;↵
|
9 | composite.setLayout(layout); | | 9 | composite.setLayout(layout);
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | Clones are in different classes |
Number of node comparisons | 35 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 8 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 0.0 |
Clone type | Type 2 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
1 | Composite composite = new Composite(parent, SWT.NONE); | | 1 | Composite composite = new Composite(parent, SWT.NONE); |
2 | composite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL)); | | 2 | composite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL)); |
3 | GridLayout layout = new GridLayout(2, false); | | 3 | GridLayout layout = new GridLayout(); |
4 | layout.marginLeft = -5; | | 4 | layout.marginLeft = -5; |
5 | layout.marginRight = -5; | | 5 | layout.marginRight = -5; |
6 | layout.marginTop = -5; | | 6 | layout.marginTop = -5; |
7 | layout.marginBottom = -5; | | 7 | layout.marginBottom = -5; |
8 | composite.setLayout(layout); | | 8 | composite.setLayout(layout); |
Precondition Violations (0)
Row |
Violation |