public void addConfiguredInputMapper(Mapper inputMapper) { if (isReference()) { throw noChildrenAllowed(); } if (this.inputMapper != null) { if (usingInput) { throw new BuildException("attribute \"input\"" + " cannot coexist with a nested <inputmapper>"); } else { throw new BuildException("Cannot have > 1 <inputmapper>"); } } this.inputMapper = inputMapper;
public void addConfiguredErrorMapper(Mapper errorMapper) { if (isReference()) { throw noChildrenAllowed(); } if (this.errorMapper != null) { if (usingError) { throw new BuildException("attribute \"error\"" + " cannot coexist with a nested <errormapper>"); } else { throw new BuildException("Cannot have > 1 <errormapper>"); } } this.errorMapper = errorMapper;
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/types/RedirectorElement.java File path: /apache-ant-1.7.0/src/org/apache/tools/ant/types/RedirectorElement.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
public void addConfiguredInputMapper(Mapper inputMapper) {
1
public void addConfiguredErrorMapper(Mapper errorMapper) {
2
        if (isReference()) {
2
        if (isReference()) {
3
            throw noChildrenAllowed();
3
            throw noChildrenAllowed();
4
        }
4
        }
5
        if (this.inputMapper != null) {
5
        if (this.errorMapper != null) {
6
            if (usingInput) {
6
            if (usingError) {
7
                throw new BuildException("attribute \"input\""
7
                throw new BuildException("attribute \"error\""
8
                    + " cannot coexist with a nested <inputmapper>");
8
                    + " cannot coexist with a nested <errormapper>");
9
            } else {
9
            } else {
10
                throw new BuildException("Cannot have > 1 <inputmapper>");
10
                throw new BuildException("Cannot have > 1 <errormapper>");
11
            }
11
            }
12
        }
12
        }
13
        this.inputMapper = inputMapper;
13
        this.errorMapper = errorMapper;
14
    
14
    
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