for ( int i = 0; i < propertySpan; i++ ) { setters[i].set( component, values[i], null ); }
for ( int j = 0; j < span; j++ ) { insert( id, fields, getPropertyInsertability(), j, getSQLInsertStrings()[j], object, session ); }
Clone fragments detected by clone detection tool
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/tuple/component/AbstractComponentTuplizer.java File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/persister/entity/AbstractEntityPersister.java
Method name: void setPropertyValues(Object, Object[]) Method name: void insert(Serializable, Object[], Object, SessionImplementor)
Number of AST nodes: 2 Number of AST nodes: 2
1
for ( int i = 0; i < propertySpan; i++ ) {
1
for ( int j = 0; j < span; j++ ) {
2
			setters[i].set( component, values[i], null );
2
				insert( id, fields, getPropertyInsertability(), j, getSQLInsertStrings()[j], object, session );
3
		}
3
			}
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.2
Clones locationClones are in different classes
Number of node comparisons4
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements2
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)1.2
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    1
    for (int i = 0; i < propertySpan; i++)
    1
    for (int i = 0; i < propertySpan; i++)
    6
    for (int j = 0; j < span; j++)
    Differences
    Expression1Expression2Difference
    ijVARIABLE_NAME_MISMATCH
    ijVARIABLE_NAME_MISMATCH
    propertySpanspanVARIABLE_NAME_MISMATCH
    ijVARIABLE_NAME_MISMATCH
    6
    for (int j = 0; j < span; j++)
    2
    setters[i].set(component, values[i], null);
    2
    setters[i].set(component, values[i], null);
    7
    insert(id, fields, getPropertyInsertability(), j, getSQLInsertStrings()[j], object, session);
    Differences
    Expression1Expression2Difference
    setinsertMETHOD_INVOCATION_NAME_MISMATCH
    setters[i].set(component,values[i],null)insert(id,fields,getPropertyInsertability(),j,getSQLInsertStrings()[j],object,session)ARGUMENT_NUMBER_MISMATCH
    setters[i]MISSING_METHOD_INVOCATION_EXPRESSION
    Preondition Violations
    Expression setters[i].set(component,values[i],null) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression insert(id,fields,getPropertyInsertability(),j,getSQLInsertStrings()[j],object,session) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression setters[i].set(component,values[i],null) is a void method call, and thus it cannot be parameterized
    Expression insert(id,fields,getPropertyInsertability(),j,getSQLInsertStrings()[j],object,session) is a void method call, and thus it cannot be parameterized
    Expression setters[i].set(component,values[i],null) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression insert(id,fields,getPropertyInsertability(),j,getSQLInsertStrings()[j],object,session) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    Expression setters[i].set(component,values[i],null) is a void method call, and thus it cannot be parameterized
    Expression insert(id,fields,getPropertyInsertability(),j,getSQLInsertStrings()[j],object,session) is a void method call, and thus it cannot be parameterized
    7
    insert(id, fields, getPropertyInsertability(), j, getSQLInsertStrings()[j], object, session);
    Precondition Violations (8)
    Row Violation
    1Expression setters[i].set(component,values[i],null) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    2Expression insert(id,fields,getPropertyInsertability(),j,getSQLInsertStrings()[j],object,session) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    3Expression setters[i].set(component,values[i],null) is a void method call, and thus it cannot be parameterized
    4Expression insert(id,fields,getPropertyInsertability(),j,getSQLInsertStrings()[j],object,session) is a void method call, and thus it cannot be parameterized
    5Expression setters[i].set(component,values[i],null) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    6Expression insert(id,fields,getPropertyInsertability(),j,getSQLInsertStrings()[j],object,session) cannot be parameterized, because it has dependencies to/from statements that will be extracted
    7Expression setters[i].set(component,values[i],null) is a void method call, and thus it cannot be parameterized
    8Expression insert(id,fields,getPropertyInsertability(),j,getSQLInsertStrings()[j],object,session) is a void method call, and thus it cannot be parameterized