org.alfresco.util.schemacomp.model
Class Table

java.lang.Object
  extended by org.alfresco.util.schemacomp.model.AbstractDbObject
      extended by org.alfresco.util.schemacomp.model.Table
All Implemented Interfaces:
DbObject

public class Table
extends AbstractDbObject

Instances of this class represent a database table.


Field Summary
 
Fields inherited from class org.alfresco.util.schemacomp.model.AbstractDbObject
comparisonUtils
 
Constructor Summary
Table(Schema parentSchema, java.lang.String name, java.util.Collection columns, PrimaryKey primaryKey, java.util.Collection foreignKeys, java.util.Collection indexes)
           
Table(java.lang.String name)
           
Table(java.lang.String name, java.util.Collection columns, PrimaryKey primaryKey, java.util.Collection foreignKeys, java.util.Collection indexes)
           
 
Method Summary
 void accept(DbObjectVisitor visitor)
          Allows a visitor to be invoked against this DbObject.
protected  void doDiff(DbObject other, DiffContext ctx, Result.Strength strength)
          Override this method to provide subclass specific diffing logic.
 boolean equals(java.lang.Object obj)
           
 java.util.List getColumns()
           
 java.util.List getForeignKeys()
           
 java.util.List getIndexes()
           
 PrimaryKey getPrimaryKey()
           
 int hashCode()
           
 void setColumns(java.util.Collection columns)
           
 void setForeignKeys(java.util.Collection foreignKeys)
           
 void setIndexes(java.util.Collection indexes)
           
 void setPrimaryKey(PrimaryKey primaryKey)
           
 
Methods inherited from class org.alfresco.util.schemacomp.model.AbstractDbObject
diff, getName, getNameStrength, getParent, getTypeName, getValidators, sameAs, setComparisonUtils, setName, setNameStrength, setParent, setValidators, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Table

public Table(java.lang.String name)

Table

public Table(java.lang.String name,
             java.util.Collection columns,
             PrimaryKey primaryKey,
             java.util.Collection foreignKeys,
             java.util.Collection indexes)

Table

public Table(Schema parentSchema,
             java.lang.String name,
             java.util.Collection columns,
             PrimaryKey primaryKey,
             java.util.Collection foreignKeys,
             java.util.Collection indexes)
Method Detail

getColumns

public java.util.List getColumns()
Returns:
the columns

setColumns

public void setColumns(java.util.Collection columns)
Parameters:
columns - the columns to set

getPrimaryKey

public PrimaryKey getPrimaryKey()
Returns:
the primaryKey

setPrimaryKey

public void setPrimaryKey(PrimaryKey primaryKey)
Parameters:
primaryKey - the primaryKey to set

getForeignKeys

public java.util.List getForeignKeys()
Returns:
the foreignKeys

setForeignKeys

public void setForeignKeys(java.util.Collection foreignKeys)
Parameters:
foreignKeys - the foreignKeys to set

getIndexes

public java.util.List getIndexes()
Returns:
the indexes

setIndexes

public void setIndexes(java.util.Collection indexes)
Parameters:
indexes - the indexes to set

hashCode

public int hashCode()
Overrides:
hashCode in class AbstractDbObject

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class AbstractDbObject

doDiff

protected void doDiff(DbObject other,
                      DiffContext ctx,
                      Result.Strength strength)
Description copied from class: AbstractDbObject
Override this method to provide subclass specific diffing logic.

Overrides:
doDiff in class AbstractDbObject

accept

public void accept(DbObjectVisitor visitor)
Description copied from interface: DbObject
Allows a visitor to be invoked against this DbObject. Implementations should ensure that child objects are visited first (by calling accept on them) before invoking the visitor on itself.



Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.