File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/gui/util/MenuFactory.java | File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/gui/util/MenuFactory.java | |||
Method name: void initializeMenus()
|
Method name: void initializeMenus()
|
|||
Number of AST nodes: 12 | Number of AST nodes: 12 | |||
1 | if (categories.contains(TIMERS)) {↵ | 1 | if (categories.contains(CONTROLLERS)) {↵ | |
2 | timers.add(new MenuInfo(item.getStaticLabel(), name));↵ | 2 | controllers.add(new MenuInfo(item.getStaticLabel(), name));↵ | |
3 | }↵ | 3 | }↵ | |
4 | if (categories.contains(POST_PROCESSORS)) {↵ | 4 | if (categories.contains(SAMPLERS)) {↵ | |
5 | postProcessors.add(new MenuInfo(item.getStaticLabel(), name));↵ | 5 | samplers.add(new MenuInfo(item.getStaticLabel(), name));↵ | |
6 | }↵ | 6 | }↵ | |
7 | if (categories.contains(PRE_PROCESSORS)) {↵ | 7 | if (categories.contains(↵ | |
8 | preProcessor↵ | 8 | NON_TEST_ELEMENTS)) {↵ | |
9 | s.add(new MenuInfo(item.getStaticLabel(), name));↵ | 9 | nonTestElements.add(new MenuInfo(item.getStaticLabel(), name));↵ | |
10 | }↵ | 10 | }↵ | |
11 | if (categories.contains(CONTROLLERS)) {↵ | 11 | if (categories.contains(LISTENERS)) {↵ | |
12 | controllers.add(new MenuInfo(item.getStaticLabel(), name));↵ | 12 | listeners.add(new MenuInfo(item.getStaticLabel(), name));↵ | |
13 | }↵ | 13 | }↵ | |
14 | if (categories.contains(SAMPLERS)) {↵ | 14 | if (categories.contains(↵ | |
15 | sampler↵ | 15 | CONFIG_ELEMENTS)) {↵ | |
16 | s.add(new MenuInfo(item.getStaticLabel(), name));↵ | 16 | configElements.add(new MenuInfo(item.getStaticLabel(), name));↵ | |
17 | }↵ | 17 | }↵ | |
18 | if (categories.contains(NON_TEST_ELEMENTS)) {↵ | 18 | if (categories.contains(↵ | |
19 | nonTestElement↵ | 19 | ASSERTIONS)) {↵ | |
20 | s.add(new MenuInfo(item.getStaticLabel(), name));↵ | 20 | assertions.add(new MenuInfo(item.getStaticLabel(), name));↵ | |
21 | } | 21 |
| |
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) | 2.4 |
Clones location | Clones are in the same method |
Number of node comparisons | 100 |
Number of mapped statements | 12 |
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) | 21.0 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
41 | if (categories.contains(TIMERS)) |
| 47 | if (categories.contains(CONTROLLERS)) | ||||||||||
42 | timers.add(new MenuInfo(item.getStaticLabel(), name)); |
| 48 | controllers.add(new MenuInfo(item.getStaticLabel(), name)); | ||||||||||
43 | if (categories.contains(POST_PROCESSORS)) |
| 49 | if (categories.contains(SAMPLERS)) | ||||||||||
44 | postProcessors.add(new MenuInfo(item.getStaticLabel(), name)); |
| 50 | samplers.add(new MenuInfo(item.getStaticLabel(), name)); | ||||||||||
45 | if (categories.contains(PRE_PROCESSORS)) |
| 51 | if (categories.contains(NON_TEST_ELEMENTS)) | ||||||||||
46 | preProcessors.add(new MenuInfo(item.getStaticLabel(), name)); |
| 52 | nonTestElements.add(new MenuInfo(item.getStaticLabel(), name)); | ||||||||||
47 | if (categories.contains(CONTROLLERS)) |
| 53 | if (categories.contains(LISTENERS)) | ||||||||||
48 | controllers.add(new MenuInfo(item.getStaticLabel(), name)); |
| 54 | listeners.add(new MenuInfo(item.getStaticLabel(), name)); | ||||||||||
49 | if (categories.contains(SAMPLERS)) |
| 55 | if (categories.contains(CONFIG_ELEMENTS)) | ||||||||||
50 | samplers.add(new MenuInfo(item.getStaticLabel(), name)); |
| 56 | configElements.add(new MenuInfo(item.getStaticLabel(), name)); | ||||||||||
51 | if (categories.contains(NON_TEST_ELEMENTS)) |
| 57 | if (categories.contains(ASSERTIONS)) | ||||||||||
52 | nonTestElements.add(new MenuInfo(item.getStaticLabel(), name)); |
| 58 | assertions.add(new MenuInfo(item.getStaticLabel(), name)); |
Row | Violation |
---|