function setPrimary( $table, $key ) {

        $this->primary[ $table ] = $key;

        // compound keys are never auto-generated,
        // so we can assume they are required
        if ( is_array( $key ) ) {

            foreach ( $key as $k ) {

                $this->setRequired( $table, $k );

            }

        }

        return $this;

    }
function setPrimary( $table, $key ) {

        $this->primary[ $table ] = $key;

        // compound keys are never auto-generated,
        // so we can assume they are required
        if ( is_array( $key ) ) {

            foreach ( $key as $k ) {

                $this->setRequired( $table, $k );

            }

        }

        return $this;

    }
function setPrimary ( $ table , $ key ) { $ this -> primary [ $ table ] = $ key ; // compound keys are never auto-generated, // so we can assume they are required if ( is_array ( $ key ) ) { foreach ( $ key as $ k ) { $ this -> setRequired ( $ table , $ k ) ; } } return $ this ; }
Set primary key of a table.
Compound keys may be passed as an array.
Always set compound primary keys explicitly with this method.

@param string $table
@param string|array $key
@return $this
Set primary key of a table . Compound keys may be passed as an array . Always set compound primary keys explicitly with this method .