private function _addTableContainers($table, $pos2, $type3, $pos3)
{
$retval = array();
if ($table->hasChildren(true) == 0) {
if ($table->getPresence('columns')) {
$retval['columns'] = NodeFactory::getInstance('NodeColumnContainer');
}
if ($table->getPresence('indexes')) {
$retval['indexes'] = NodeFactory::getInstance('NodeIndexContainer');
}
if ($table->getPresence('triggers')) {
$retval['triggers'] = NodeFactory::getInstance('NodeTriggerContainer');
}
// Add all new Nodes to the tree
foreach ($retval as $node) {
$node->pos2 = $pos2;
if ($type3 == $node->real_name) {
$node->pos3 = $pos3;
}
$table->addChild($node);
}
} else {
foreach ($table->children as $node) {
if ($type3 == $node->real_name) {
$node->pos3 = $pos3;
}
$retval[$node->real_name] = $node;
}
}
return $retval;
}