當前位置: 首頁>>代碼示例>>PHP>>正文


PHP AbstractSchemaManager::_getPortableTableForeignKeysList方法代碼示例

本文整理匯總了PHP中Doctrine\DBAL\Schema\AbstractSchemaManager::_getPortableTableForeignKeysList方法的典型用法代碼示例。如果您正苦於以下問題:PHP AbstractSchemaManager::_getPortableTableForeignKeysList方法的具體用法?PHP AbstractSchemaManager::_getPortableTableForeignKeysList怎麽用?PHP AbstractSchemaManager::_getPortableTableForeignKeysList使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Doctrine\DBAL\Schema\AbstractSchemaManager的用法示例。


在下文中一共展示了AbstractSchemaManager::_getPortableTableForeignKeysList方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: _getPortableTableForeignKeysList

 /**
  * {@inheritdoc}
  */
 protected function _getPortableTableForeignKeysList($tableForeignKeys)
 {
     $foreignKeys = array();
     foreach ($tableForeignKeys as $tableForeignKey) {
         if (!isset($foreignKeys[$tableForeignKey['index_name']])) {
             $foreignKeys[$tableForeignKey['index_name']] = array('local_columns' => array($tableForeignKey['local_column']), 'foreign_table' => $tableForeignKey['foreign_table'], 'foreign_columns' => array($tableForeignKey['foreign_column']), 'name' => $tableForeignKey['index_name'], 'options' => array('notnull' => $tableForeignKey['notnull'], 'match' => $tableForeignKey['match'], 'onUpdate' => $tableForeignKey['on_update'], 'onDelete' => $tableForeignKey['on_delete'], 'check_on_commit' => $tableForeignKey['check_on_commit'], 'clustered' => $tableForeignKey['clustered'], 'for_olap_workload' => $tableForeignKey['for_olap_workload']));
         } else {
             $foreignKeys[$tableForeignKey['index_name']]['local_columns'][] = $tableForeignKey['local_column'];
             $foreignKeys[$tableForeignKey['index_name']]['foreign_columns'][] = $tableForeignKey['foreign_column'];
         }
     }
     return parent::_getPortableTableForeignKeysList($foreignKeys);
 }
開發者ID:Dren-x,項目名稱:mobit,代碼行數:16,代碼來源:SQLAnywhereSchemaManager.php

示例2: _getPortableTableForeignKeysList

 /**
  * {@inheritdoc}
  */
 protected function _getPortableTableForeignKeysList($tableForeignKeys)
 {
     $foreignKeys = array();
     foreach ($tableForeignKeys as $tableForeignKey) {
         if (!isset($foreignKeys[$tableForeignKey['ForeignKey']])) {
             $foreignKeys[$tableForeignKey['ForeignKey']] = array('local_columns' => array($tableForeignKey['ColumnName']), 'foreign_table' => $tableForeignKey['ReferenceTableName'], 'foreign_columns' => array($tableForeignKey['ReferenceColumnName']), 'name' => $tableForeignKey['ForeignKey'], 'options' => array('onUpdate' => str_replace('_', ' ', $tableForeignKey['update_referential_action_desc']), 'onDelete' => str_replace('_', ' ', $tableForeignKey['delete_referential_action_desc'])));
         } else {
             $foreignKeys[$tableForeignKey['ForeignKey']]['local_columns'][] = $tableForeignKey['ColumnName'];
             $foreignKeys[$tableForeignKey['ForeignKey']]['foreign_columns'][] = $tableForeignKey['ReferenceColumnName'];
         }
     }
     return parent::_getPortableTableForeignKeysList($foreignKeys);
 }
開發者ID:TuxCoffeeCorner,項目名稱:tcc,代碼行數:16,代碼來源:SQLServerSchemaManager.php

示例3: _getPortableTableForeignKeysList

 /**
  * {@inheritdoc}
  */
 protected function _getPortableTableForeignKeysList($tableForeignKeys)
 {
     $foreignKeys = array();
     foreach ($tableForeignKeys as $tableForeignKey) {
         $tableForeignKey = array_change_key_case($tableForeignKey, \CASE_LOWER);
         if (!isset($foreignKeys[$tableForeignKey['constraint_name']])) {
             $foreignKeys[$tableForeignKey['constraint_name']] = array('local_columns' => array($tableForeignKey['local_column']), 'foreign_table' => $tableForeignKey['foreign_table'], 'foreign_columns' => array($tableForeignKey['foreign_column']), 'name' => $tableForeignKey['constraint_name'], 'options' => array('onUpdate' => $tableForeignKey['update_rule'], 'onDelete' => $tableForeignKey['delete_rule']));
         } else {
             $foreignKeys[$tableForeignKey['constraint_name']]['local_columns'][] = $tableForeignKey['local_column'];
             $foreignKeys[$tableForeignKey['constraint_name']]['foreign_columns'][] = $tableForeignKey['foreign_column'];
         }
     }
     return parent::_getPortableTableForeignKeysList($foreignKeys);
 }
開發者ID:rpeterson,項目名稱:laravel-fdb,代碼行數:17,代碼來源:FoundationDBSQLSchemaManager.php


注:本文中的Doctrine\DBAL\Schema\AbstractSchemaManager::_getPortableTableForeignKeysList方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。