File path: /sql12/app/src/net/sourceforge/squirrel_sql/client/session/properties/SessionProperties.java | File path: /sql12/app/src/net/sourceforge/squirrel_sql/client/session/properties/SessionProperties.java | |||
Method name: void setSQLNbrRowsToShow(int)
|
Method name: void setSqlResultTabLimit(int)
|
|||
Number of AST nodes: 4 | Number of AST nodes: 4 | |||
1 | if (_sqlNbrRowsToShow != value)↵ | 1 | if (_sqlResultTabLimit != value)↵ | |
2 | {↵ | 2 | {↵ | |
3 | final int oldValue = _sqlNbrRowsToShow;↵ | 3 | int oldValue = _sqlResultTabLimit;↵ | |
4 | _sqlNbrRowsToShow = value;↵ | 4 | _sqlResultTabLimit = value;↵ | |
5 | getPropertyChangeReporter().firePropertyChange(↵ | 5 | getPropertyChangeReporter().firePropertyChange(↵ | |
6 | IPropertyNames.SQL_NBR_ROWS_TO_SHOW,↵ | 6 | IPropertyNames.SQL_RESULT_TAB_LIMIT,↵ | |
7 | oldValue, _sqlNbrRowsToShow);↵ | 7 | oldValue, _sqlResultTabLimit);↵ | |
8 | } | 8 |
| |
See real code fragment | See real code fragment |
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.1 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 16 |
Number of mapped statements | 3 |
Number of unmapped statements in the first code fragment | 1 |
Number of unmapped statements in the second code fragment | 1 |
Time elapsed for statement mapping (ms) | 1.5 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | if (_sqlNbrRowsToShow != value) |
| 1 | if (_sqlResultTabLimit != value) | |||||||||||||
|
| 2 | int oldValue = _sqlResultTabLimit; | ||||||||||||||
2 | final int oldValue = _sqlNbrRowsToShow; |
| | ||||||||||||||
3 | _sqlNbrRowsToShow = value; |
| 3 | _sqlResultTabLimit = value; | |||||||||||||
4 | getPropertyChangeReporter().firePropertyChange(IPropertyNames.SQL_NBR_ROWS_TO_SHOW, oldValue, _sqlNbrRowsToShow); |
| 4 | getPropertyChangeReporter().firePropertyChange(IPropertyNames.SQL_RESULT_TAB_LIMIT, oldValue, _sqlResultTabLimit); |
Row | Violation |
---|---|
1 | Unmatched statement int oldValue=_sqlResultTabLimit; cannot be moved before the extracted code, because it has control dependencies from statements that will be extracted |
2 | Unmatched statement final int oldValue=_sqlNbrRowsToShow; cannot be moved before the extracted code, because it has control dependencies from statements that will be extracted |