ALF-10772: schema comparator

Compares two abstract database schemas.



git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@31312 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Matt Ward
2011-10-18 11:42:57 +00:00
parent 4cde60f0e6
commit 2a5a337b4e
14 changed files with 799 additions and 139 deletions

View File

@@ -20,8 +20,12 @@ package org.alfresco.util.schemacomp.model;
import java.util.List;
import org.alfresco.util.schemacomp.Differences;
import org.alfresco.util.schemacomp.SchemaUtils;
/**
* TODO: comment me!
* Primary key on a table.
*
* @author Matt Ward
*/
public class PrimaryKey extends AbstractDbObject
@@ -68,4 +72,11 @@ public class PrimaryKey extends AbstractDbObject
else if (!this.columnNames.equals(other.columnNames)) return false;
return true;
}
@Override
protected void doDiff(DbObject right, Differences differences)
{
PrimaryKey rightPK = (PrimaryKey) right;
SchemaUtils.compareSimpleCollections(columnNames, rightPK.columnNames, differences);
}
}