if (_fkInfo != null)
{
return;
}
DescriptorRepository repos = broker.getDescriptorRepository();
_fkInfo = new HashMap();
for (Iterator it = repos.iterator(); it.hasNext();)
{
ClassDescriptor desc = (ClassDescriptor) it.next();
List ordList = desc.getObjectReferenceDescriptors();
if (!ordList.isEmpty())
{
HashSet fkTables = getFKTablesFor(desc.getFullTableName());
for (Iterator it2 = ordList.iterator(); it2.hasNext();)
{
ObjectReferenceDescriptor ord = (ObjectReferenceDescriptor) it2.next();
ClassDescriptor oneDesc = repos.getDescriptorFor(ord.getItemClass());
fkTables.addAll(getFullTableNames(oneDesc, repos));
}
}
List codList = desc.getCollectionDescriptors();
for (Iterator it2 = codList.iterator(); it2.hasNext();)
{
CollectionDescriptor cod = (CollectionDescriptor) it2.next();
ClassDescriptor manyDesc = repos.getDescriptorFor(cod.getItemClass());
if (cod.isMtoNRelation())
{
HashSet fkTables = getFKTablesFor(cod.getIndirectionTable());
fkTables.addAll(getFullTableNames(desc, repos));
fkTables.addAll(getFullTableNames(manyDesc, repos));