void initializeTableModel() { tableModel = new ObjectTableModel(new String[] { COLUMN_NAMES[0], COLUMN_NAMES[1], COLUMN_NAMES[2] }, LDAPArgument.class, new Functor[] { new Functor("getName"), new Functor("getValue"), new Functor("getOpcode") }, new Functor[] { new Functor("setName"), new Functor("setValue"), new Functor("setOpcode") }, new Class[] { String.class, String.class, String.class }); } public static boolean testFunctors(){ LDAPArgumentsPanel instance = new LDAPArgumentsPanel(); instance.initializeTableModel(); return instance.tableModel.checkFunctors(null,instance.getClass());
void initializeTableModel() { tableModel = new ObjectTableModel(new String[] { ArgumentsPanel.COLUMN_NAMES_0, ArgumentsPanel.COLUMN_NAMES_1, ENCODE_OR_NOT, INCLUDE_EQUALS }, HTTPArgument.class, new Functor[] { new Functor("getName"), //$NON-NLS-1$ new Functor("getValue"), //$NON-NLS-1$ new Functor("isAlwaysEncoded"), //$NON-NLS-1$ new Functor("isUseEquals") }, //$NON-NLS-1$ new Functor[] { new Functor("setName"), //$NON-NLS-1$ new Functor("setValue"), //$NON-NLS-1$ new Functor("setAlwaysEncoded"), //$NON-NLS-1$ new Functor("setUseEquals") }, //$NON-NLS-1$ new Class[] {String.class, String.class, Boolean.class, Boolean.class }); } public static boolean testFunctors(){ HTTPArgumentsPanel instance = new HTTPArgumentsPanel(); instance.initializeTableModel(); return instance.tableModel.checkFunctors(null,instance.getClass());
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/ldap/config/gui/LDAPArgumentsPanel.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/http/gui/HTTPArgumentsPanel.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
void initializeTableModel() {
1
void initializeTableModel() {
2
		tableModel = new ObjectTableModel(new String[] { COLUMN_NAMES[0], COLUMN_NAMES[1], COLUMN_NAMES[2]
2
		tableModel = new ObjectTableModel(new String[] {
3
 },
3
				ArgumentsPanel.COLUMN_NAMES_0, ArgumentsPanel.COLUMN_NAMES_1, ENCODE_OR_NOT, INCLUDE_EQUALS },
4
				LDAPArgument.class,
4
				HTTPArgument.class,
5
				new Functor[] { 
5
				new Functor[] {
6
new Functor("getName"), 
6
				new Functor("getName"), //$NON-NLS-1$
7
new Functor("getValue"), new Functor("getOpcode") },
7
				new Functor("getValue"), //$NON-NLS-1$
8
				new Functor("isAlwaysEncoded"), //$NON-NLS-1$
9
				new Functor("isUseEquals") }, //$NON-NLS-1$
8
				new Functor[] { 
10
				new Functor[] { 
9
new Functor("setName"), 
11
				new Functor("setName"), //$NON-NLS-1$
10
new Functor("setValue"), new Functor("setOpcode") },
12
				new Functor("setValue"), //$NON-NLS-1$
13
				new Functor("setAlwaysEncoded"), //$NON-NLS-1$
14
				new Functor("setUseEquals") }, //$NON-NLS-1$
11
				new Class[] { String.class, String.class, String.class });
15
				new Class[] {String.class, String.class, Boolean.class, Boolean.class });
12
	}
16
	}
13
	public static boolean testFunctors(){
17
	public static boolean testFunctors(){
14
		LDAPArgumentsPanel instance = new LDAPArgumentsPanel();
18
		HTTPArgumentsPanel instance = new HTTPArgumentsPanel();
15
		instance.initializeTableModel();
19
		instance.initializeTableModel();
16
		return instance.tableModel.checkFunctors(null,instance.getClass());
20
		return instance.tableModel.checkFunctors(null,instance.getClass());
17
	
21
	
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones location
Number of node comparisons0