public void setSystemProperties() { Properties systemP = System.getProperties(); Enumeration e = systemP.propertyNames(); while (e.hasMoreElements()) { String propertyName = (String) e.nextElement(); String value = systemP.getProperty(propertyName); this.setPropertyInternal(propertyName, value);
protected void fireTaskStarted(Task task) { // register this as the current task on the current thread. registerThreadTask(Thread.currentThread(), task); BuildEvent event = new BuildEvent(task); Iterator iter = listeners.iterator(); while (iter.hasNext()) { BuildListener listener = (BuildListener) iter.next(); listener.taskStarted(event);
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/Project.java File path: /apache-ant-1.7.0/src/org/apache/tools/ant/Project.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
public void setSystemProperties() {
1
protected void fireTaskStarted(Task task) {
2
        Properties systemP = System.getProperties();
2
        
3
        Enumeration e
3
// register this as the current task on the current thread.
4
        registerThreadTask(Thread.currentThread(), task);
5
        BuildEvent event = new BuildEvent(task);
4
 = systemP.propertyNames();
6
        Iterator iter = listeners.iterator();
5
        while (e.hasMoreElements()) {
7
        while (iter.hasNext()) {
6
            String propertyName = (String) e.nextElement();
8
            
7
            String value = systemP.getProperty(propertyName);
8
            this.setPropertyInternal(propertyName, value
9
BuildListener listener = (BuildListener) iter.next();
9
);
10
            listener.taskStarted(event);
10
        
11
        
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