monthlyWestDateHeaderBean.setHeaderRows(new CellDecorationRow[] {
// showing the week number
new CellDecorationRow(DateRangeI.RANGE_TYPE_WEEK,
new DateFormatList("'w'w", null), new AtFixed(24f),
new AbsRect(new AtStart(0.0f), new AtStart(0.0f),
new AtEnd(0.0f), new AtEnd(0.0f), null, null,
null), (java.awt.Paint[]) null,
new java.awt.Paint[] { labelColor },
new DefaultRepetition(0, 1, null, null),
new java.awt.Font[] { UIManager.getFont("Label.font")
.deriveFont(9f) },
new java.lang.Integer[] { null }, new AtFraction(0.5f),
new AtStart(4f)) });
monthlyWestDateHeaderBean
.setBackgroundPaint(new com.miginfocom.util.gfx.ShapeGradientPaint(
new java.awt.Color(255, 255, 255), new java.awt.Color(
247, 247, 247), 0.0f, 0.7f, 0.6f, false));
monthlyWestDateHeaderBean
.setTextAntiAlias(com.miginfocom.util.gfx.GfxUtil.AA_HINT_ON);
eastDateHeaderBean
.setHeaderRows(new CellDecorationRow[] {
// showing the month number
new CellDecorationRow(
DateRangeI.RANGE_TYPE_MONTH,
new DateFormatList("MMMM|MMM", null),
new AtFixed(17f),
new AbsRect(new AtStart(0.0f), new AtStart(0.0f),
new AtEnd(0.0f), new AtEnd(0.0f), null, null,
null),
(java.awt.Paint[]) null,
new java.awt.Paint[] { labelColor },
new DefaultRepetition(0, 1, null, null),
new java.awt.Font[] { UIManager.getFont("Label.font") },
new java.lang.Integer[] { null }, new AtFraction(0.5f),
new AtStart(4f)) });
eastDateHeaderBean
.setBackgroundPaint(new com.miginfocom.util.gfx.ShapeGradientPaint(
new java.awt.Color(255, 255, 255), new java.awt.Color(
247, 247, 247), 180.0f, 0.7f, 0.6f, false));
eastDateHeaderBean
.setTextAntiAlias(com.miginfocom.util.gfx.GfxUtil.AA_HINT_ON);
Clone fragments detected by clone detection tool
File path: /columba-1.4-src/calendar/src/main/java/org/columba/calendar/ui/navigation/DateAreaBeanFactory.java
|
|
File path: /columba-1.4-src/calendar/src/main/java/org/columba/calendar/ui/navigation/DateAreaBeanFactory.java
|
Method name: DateAreaBean initDateArea()
|
|
Method name: DateAreaBean initDateArea()
|
Number of AST nodes: 3
|
|
Number of AST nodes: 3
|
|
1 | monthlyWestDateHeaderBean↵ | | 1 | eastDateHeaderBean↵
|
2 | .setHeaderRows(new CellDecorationRow[] {↵ | | 2 | .setHeaderRows(new CellDecorationRow[] {↵
|
3 | // showing the week number↵ | | 3 | // showing the month number↵
|
4 | new CellDecorationRow(↵ | | 4 | new CellDecorationRow(↵
|
5 | DateRangeI.RANGE_TYPE_WEEK,↵ | | 5 | DateRangeI.RANGE_TYPE_MONTH,↵
|
6 | new DateFormatList("'w'w", null), ↵ | | 6 | new DateFormatList("MMMM|MMM", null),↵
|
7 | new AtFixed(24f),↵ | | 7 | new AtFixed(17f),↵
|
8 | new AbsRect(new AtStart(0.0f), new AtStart(0.0f),↵ | | 8 | new AbsRect(new AtStart(0.0f), new AtStart(0.0f),↵
|
9 | new AtEnd(0.0f), new AtEnd(0.0f), null, null,↵ | | 9 | new AtEnd(0.0f), new AtEnd(0.0f), null, null,↵
|
10 | null), ↵ | | 10 | null),↵
|
11 | (java.awt.Paint[]) null,↵ | | 11 | (java.awt.Paint[]) null,↵
|
12 | new java.awt.Paint[] { labelColor },↵ | | 12 | new java.awt.Paint[] { labelColor },↵
|
13 | new DefaultRepetition(0, 1, null, null),↵ | | 13 | new DefaultRepetition(0, 1, null, null),↵
|
14 | new java.awt.Font[] { UIManager.getFont("Label.font")↵ | | 14 | new java.awt.Font[] { UIManager.getFont("Label.font")↵
|
15 | .deriveFont(9f) },↵ | | 15 | },↵
|
16 | new java.lang.Integer[] { null }, new AtFraction(0.5f),↵ | | 16 | new java.lang.Integer[] { null }, new AtFraction(0.5f),↵
|
17 | new AtStart(4f)) });↵ | | 17 | new AtStart(4f)) });↵
|
|
18 | monthlyWestDateHeaderBean↵ | | 18 | eastDateHeaderBean↵
|
19 | .setBackgroundPaint(new com.miginfocom.util.gfx.ShapeGradientPaint(↵ | | 19 | .setBackgroundPaint(new com.miginfocom.util.gfx.ShapeGradientPaint(↵
|
20 | new java.awt.Color(255, 255, 255), new java.awt.Color(↵ | | 20 | new java.awt.Color(255, 255, 255), new java.awt.Color(↵
|
21 | 247, 247, 247), 0.0f, 0.7f, 0.6f, false));↵ | | 21 | 247, 247, 247), 180.0f, 0.7f, 0.6f, false));↵
|
|
22 | monthlyWestDateHeaderBean↵ | | 22 | eastDateHeaderBean↵
|
23 | .setTextAntiAlias(com.miginfocom.util.gfx.GfxUtil.AA_HINT_ON); | | 23 | .setTextAntiAlias(com.miginfocom.util.gfx.GfxUtil.AA_HINT_ON);
|
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 the same method |
Number of node comparisons | 9 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 2 |
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) | 0.0 |
Clone type | Type 2 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
7 | monthlyWestDateHeaderBean.setHeaderRows(new CellDecorationRow[] {new CellDecorationRow(DateRangeI.RANGE_TYPE_WEEK, new DateFormatList("'w'w", null), new AtFixed(24f), new AbsRect(new AtStart(0.0f), new AtStart(0.0f), new AtEnd(0.0f), new AtEnd(0.0f), null, null, null), (java.awt.Paint[])null, new java.awt.Paint[] {labelColor}, new DefaultRepetition(0, 1, null, null), new java.awt.Font[] {UIManager.getFont("Label.font").deriveFont(9f)}, new java.lang.Integer[] {null}, new AtFraction(0.5f), new AtStart(4f))}); | | | |
| | | 11 | eastDateHeaderBean.setHeaderRows(new CellDecorationRow[] {new CellDecorationRow(DateRangeI.RANGE_TYPE_MONTH, new DateFormatList("MMMM|MMM", null), new AtFixed(17f), new AbsRect(new AtStart(0.0f), new AtStart(0.0f), new AtEnd(0.0f), new AtEnd(0.0f), null, null, null), (java.awt.Paint[])null, new java.awt.Paint[] {labelColor}, new DefaultRepetition(0, 1, null, null), new java.awt.Font[] {UIManager.getFont("Label.font")}, new java.lang.Integer[] {null}, new AtFraction(0.5f), new AtStart(4f))}); |
8 | monthlyWestDateHeaderBean.setBackgroundPaint(new com.miginfocom.util.gfx.ShapeGradientPaint(new java.awt.Color(255, 255, 255), new java.awt.Color(247, 247, 247), 0.0f, 0.7f, 0.6f, false)); | | 12 | eastDateHeaderBean.setBackgroundPaint(new com.miginfocom.util.gfx.ShapeGradientPaint(new java.awt.Color(255, 255, 255), new java.awt.Color(247, 247, 247), 180.0f, 0.7f, 0.6f, false)); |
9 | monthlyWestDateHeaderBean.setTextAntiAlias(com.miginfocom.util.gfx.GfxUtil.AA_HINT_ON); | | 13 | eastDateHeaderBean.setTextAntiAlias(com.miginfocom.util.gfx.GfxUtil.AA_HINT_ON); |
Precondition Violations (0)
Row |
Violation |