this.query = query; this.cacheable = cacheable; this.cacheRegion = cacheRegion; this.timeout = timeout; this.fetchSize = fetchSize; this.flushMode = flushMode; this.parameterTypes = parameterTypes; this.cacheMode = cacheMode; this.readOnly = readOnly; this.comment = comment;
this.sqlQueryString = sqlQueryString; this.positionalParameterTypes = positionalParameterTypes; this.positionalParameterValues = positionalParameterValues; this.namedParameters = namedParameters; this.firstRow = firstRow; this.maxRows = maxRows; this.entityMode = entityMode; this.filterKeys = filterKeys; this.customTransformer = customTransformer; this.hashCode = generateHashCode();
Clone fragments detected by clone detection tool
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/engine/NamedQueryDefinition.java File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/cache/QueryKey.java
Method name: void NamedQueryDefinition(String, boolean, String, Integer, Integer, FlushMode, CacheMode, boolean, String, Map) Method name: void QueryKey(String, Type[], Object[], Map, Integer, Integer, Set, EntityMode, ResultTransformer)
Number of AST nodes: 10 Number of AST nodes: 10
1
this.query = query;
1
this.
2
		this.cacheable = cacheable;
3
		this.cacheRegion = cacheRegion;
4
		this.timeout = timeout;
5
		this.fetchSize = fetchSize
2
sqlQueryString = sqlQueryString;
3
		this.positionalParameterTypes = positionalParameterTypes;
4
		this.positionalParameterValues = positionalParameterValues;
6
;
5
		this.namedParameters = namedParameters;
7
		this.flushMode = flushMode;
6
		this.f
8
		this.parameterTypes = parameterType
7
irstRow = firstRow;
9
s;
8
		this.maxRows = maxRows;
10
		this.cacheMode = cacheMode;
9
		this.entityMode = entityMode;
11
		this.readOnly = readOnly;
10
		this.
12
		this.comment = comment
11
filterKeys = filterKeys;
12
		this.customTransformer = customTransformer;
13
;
13
		this.hashCode = generateHashCode();
Summary
Number of common nesting structure subtrees1
Number of refactorable cases0
Number of non-refactorable cases1
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones locationClones are in different classes
Number of node comparisons76
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements4
    Number of unmapped statements in the first code fragment6
    Number of unmapped statements in the second code fragment6
    Time elapsed for statement mapping (ms)0.0
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    1
    this.query = query;
    1
    this.query = query;
    1
    this.sqlQueryString = sqlQueryString;
    Differences
    Expression1Expression2Difference
    querysqlQueryStringVARIABLE_NAME_MISMATCH
    querysqlQueryStringVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression this.query is a field being modified, and thus it cannot be parameterized
    Expression this.sqlQueryString is a field being modified, and thus it cannot be parameterized
    1
    this.sqlQueryString = sqlQueryString;
                                                                                                                        
    2
    this.positionalParameterTypes = positionalParameterTypes;
    2
    this.cacheable = cacheable;
                                                            
                                                                                                                            
    3
    this.positionalParameterValues = positionalParameterValues;
    3
    this.cacheRegion = cacheRegion;
                                                                    
    4
    this.timeout = timeout;
    4
    this.timeout = timeout;
    5
    this.firstRow = firstRow;
    Differences
    Expression1Expression2Difference
    timeoutfirstRowVARIABLE_NAME_MISMATCH
    timeoutfirstRowVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression this.timeout is a field being modified, and thus it cannot be parameterized
    Expression this.firstRow is a field being modified, and thus it cannot be parameterized
    5
    this.firstRow = firstRow;
    5
    this.fetchSize = fetchSize;
    5
    this.fetchSize = fetchSize;
    6
    this.maxRows = maxRows;
    Differences
    Expression1Expression2Difference
    fetchSizemaxRowsVARIABLE_NAME_MISMATCH
    fetchSizemaxRowsVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression this.fetchSize is a field being modified, and thus it cannot be parameterized
    Expression this.maxRows is a field being modified, and thus it cannot be parameterized
    6
    this.maxRows = maxRows;
    6
    this.flushMode = flushMode;
                                                            
    7
    this.parameterTypes = parameterTypes;
    7
    this.parameterTypes = parameterTypes;
    4
    this.namedParameters = namedParameters;
    Differences
    Expression1Expression2Difference
    parameterTypesnamedParametersVARIABLE_NAME_MISMATCH
    parameterTypesnamedParametersVARIABLE_NAME_MISMATCH
    Preondition Violations
    Expression this.parameterTypes is a field being modified, and thus it cannot be parameterized
    Expression this.namedParameters is a field being modified, and thus it cannot be parameterized
    4
    this.namedParameters = namedParameters;
                                                                
    7
    this.entityMode = entityMode;
                                                                
    8
    this.filterKeys = filterKeys;
    8
    this.cacheMode = cacheMode;
                                                            
                                                                                            
    9
    this.customTransformer = customTransformer;
    9
    this.readOnly = readOnly;
                                                        
                                                                              
    10
    this.hashCode = generateHashCode();
    10
    this.comment = comment;
                                                      
    Precondition Violations (8)
    Row Violation
    1Expression this.query is a field being modified, and thus it cannot be parameterized
    2Expression this.sqlQueryString is a field being modified, and thus it cannot be parameterized
    3Expression this.timeout is a field being modified, and thus it cannot be parameterized
    4Expression this.firstRow is a field being modified, and thus it cannot be parameterized
    5Expression this.fetchSize is a field being modified, and thus it cannot be parameterized
    6Expression this.maxRows is a field being modified, and thus it cannot be parameterized
    7Expression this.parameterTypes is a field being modified, and thus it cannot be parameterized
    8Expression this.namedParameters is a field being modified, and thus it cannot be parameterized