original_string: static public function validate( ezcDbSchema $schema )
      {
          $indexes = array();
          $errors = array();
  
          /* For each table we check all auto increment fields. */
          foreach ( $schema->getSchema() as $tableName => $table )
          {
              foreach ( $table->indexes as $indexName => $dummy )
              {
                  $indexes[$indexName][] = $tableName;
              }
          }
  
          foreach ( $indexes as $indexName => $tableList )
          {
              if ( count( $tableList ) > 1 )
              {
                  $errors[] = "The index name '$indexName' is not unique. It exists for the tables: '" . join( "', '", $tableList ) . "'.";
              }
          }
  
          return $errors;
      }
code: static public function validate( ezcDbSchema $schema )
      {
          $indexes = array();
          $errors = array();
  
          /* For each table we check all auto increment fields. */
          foreach ( $schema->getSchema() as $tableName => $table )
          {
              foreach ( $table->indexes as $indexName => $dummy )
              {
                  $indexes[$indexName][] = $tableName;
              }
          }
  
          foreach ( $indexes as $indexName => $tableList )
          {
              if ( count( $tableList ) > 1 )
              {
                  $errors[] = "The index name '$indexName' is not unique. It exists for the tables: '" . join( "', '", $tableList ) . "'.";
              }
          }
  
          return $errors;
      }
code_tokens: static public function validate ( ezcDbSchema $ schema ) { $ indexes = array ( ) ; $ errors = array ( ) ; /* For each table we check all auto increment fields. */ foreach ( $ schema -> getSchema ( ) as $ tableName => $ table ) { foreach ( $ table -> indexes as $ indexName => $ dummy ) { $ indexes [ $ indexName ] [ ] = $ tableName ; } } foreach ( $ indexes as $ indexName => $ tableList ) { if ( count ( $ tableList ) > 1 ) { $ errors [ ] = "The index name '$indexName' is not unique. It exists for the tables: '" . join ( "', '" , $ tableList ) . "'." ; } } return $ errors ; }
docstring: Validates if all the index names used are unique accross the schema.
  
  This method loops over all the indexes in all tables and checks whether
  they have been used before.
  
  @param ezcDbSchema $schema
  @return array(string)
docstring_tokens: Validates if all the index names used are unique accross the schema .