File location = fc.getSelectedFile(); Profile p = new Profile(location.getName(), location); // add profile to profiles.xml ProfileManager.getInstance().addProfile(p); // add to listmodel model.addElement(p.getName()); // select new item list.setSelectedValue(p.getName(), true);
List authMechanisms = AuthenticationFactory.getInstance() .getSupportedMechanisms(oneLine.toString()); Iterator it = authMechanisms.iterator(); while (it.hasNext()) { supportedMechanisms.add(new Integer(AuthenticationManager .getSaslCode((String) it.next()))); }
Clone fragments detected by clone detection tool
File path: /columba-1.4-src/core/src/main/java/org/columba/core/gui/profiles/ProfileManagerDialog.java File path: /columba-1.4-src/mail/src/main/java/org/columba/mail/imap/IMAPServer.java
Method name: void actionPerformed(ActionEvent) Method name: List checkSupportedAuthenticationMethods()
Number of AST nodes: 5 Number of AST nodes: 4
1
File location = fc.getSelectedFile();
2
				Profile p = new Profile(location.getName(), location);
3
				// add profile to profiles.xml
4
				ProfileManager.getInstance().addProfile(p
1
List authMechanisms = AuthenticationFactory.getInstance()
5
);
2
						.getSupportedMechanisms(oneLine.toString());
6
				// add to listmodel
3
				
7
				model.addElement(p.getName
4
Iterator it = authMechanisms.iterator();
8
());
5
				while (it.hasNext()) {
9
				// select new item
6
				
10
				list.setSelectedValue(p.getName(), true);
7
	supportedMechanisms.add(new Integer(AuthenticationManager
8
							.getSaslCode((String) it.next())));
9
				}
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 locationClones are in different classes
Number of node comparisons10