public function indexCompare(array $a, array $b) {
        if ($a['columns'] > $b['columns']) {
            return 1;
        } elseif ($a['columns'] < $b['columns']) {
            return -1;
        }

        return strcmp(val('type', $a, ''), val('type', $b, ''));
    }
public function indexCompare(array $a, array $b) {
        if ($a['columns'] > $b['columns']) {
            return 1;
        } elseif ($a['columns'] < $b['columns']) {
            return -1;
        }

        return strcmp(val('type', $a, ''), val('type', $b, ''));
    }
public function indexCompare ( array $ a , array $ b ) { if ( $ a [ 'columns' ] > $ b [ 'columns' ] ) { return 1 ; } elseif ( $ a [ 'columns' ] < $ b [ 'columns' ] ) { return - 1 ; } return strcmp ( val ( 'type' , $ a , '' ) , val ( 'type' , $ b , '' ) ) ; }
Compare two index definitions to see if they have the same columns and same type.

@param array $a The first index.
@param array $b The second index.
@return int Returns an integer less than, equal to, or greater than zero if {@link $a} is
considered to be respectively less than, equal to, or greater than {@link $b}.
Compare two index definitions to see if they have the same columns and same type .