File path: /jfreechart-1.0.10/src/org/jfree/chart/block/AbstractBlock.java | File path: /jfreechart-1.0.10/src/org/jfree/chart/block/AbstractBlock.java | |||
Method name: double trimToContentWidth(double)
|
Method name: double trimToContentHeight(double)
|
|||
Number of AST nodes: 4 | Number of AST nodes: 4 | |||
1 | double result = this.margin.trimWidth(fixedWidth);↵ | 1 | double result = this.margin.trimHeight(fixedHeight);↵ | |
2 | result = this.frame.getInsets().trimWidth(result);↵ | 2 | result = this.frame.getInsets().trimHeight(result);↵ | |
3 | result = this.padding.trimWidth(result);↵ | 3 | result = this.padding.trimHeight(result);↵ | |
4 | return Math.max(result, 0.0); | 4 |
| |
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.0 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 16 |
Number of mapped statements | 4 |
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 |
ID | Statement | ID | Statement | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | double result = this.margin.trimWidth(fixedWidth); |
| 1 | double result = this.margin.trimHeight(fixedHeight); | |||||||||||||
2 | result = this.frame.getInsets().trimWidth(result); |
| 2 | result = this.frame.getInsets().trimHeight(result); | |||||||||||||
3 | result = this.padding.trimWidth(result); |
| 3 | result = this.padding.trimHeight(result); | |||||||||||||
4 | return Math.max(result, 0.0); | 4 | return Math.max(result, 0.0); |
Row | Violation |
---|---|
1 | Expression this.frame.getInsets().trimWidth(result) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression this.frame.getInsets().trimHeight(result) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
3 | Expression this.padding.trimWidth(result) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
4 | Expression this.padding.trimHeight(result) cannot be parameterized, because it has dependencies to/from statements that will be extracted |