public function isLocalPrimaryKey()
    {
        $localPKCols = [];
        foreach ($this->parentTable->getPrimaryKey() as $lPKCol) {
            $localPKCols[] = $lPKCol->getName();
        }

        return count($localPKCols) === count($this->localColumns) && !array_diff($localPKCols, $this->localColumns);
    }
public function isLocalPrimaryKey()
    {
        $localPKCols = [];
        foreach ($this->parentTable->getPrimaryKey() as $lPKCol) {
            $localPKCols[] = $lPKCol->getName();
        }

        return count($localPKCols) === count($this->localColumns) && !array_diff($localPKCols, $this->localColumns);
    }
public function isLocalPrimaryKey ( ) { $ localPKCols = [ ] ; foreach ( $ this -> parentTable -> getPrimaryKey ( ) as $ lPKCol ) { $ localPKCols [ ] = $ lPKCol -> getName ( ) ; } return count ( $ localPKCols ) === count ( $ this -> localColumns ) && ! array_diff ( $ localPKCols , $ this -> localColumns ) ; }
Returns whether or not this foreign key is also the primary key of
the local table.

@return boolean True if all local columns are at the same time a primary key
Returns whether or not this foreign key is also the primary key of the local table .