protected function _junctionTableName($name = null)
    {
        if ($name === null) {
            if (empty($this->_junctionTableName)) {
                $tablesNames = array_map('Cake\Utility\Inflector::underscore', [
                    $this->getSource()->getTable(),
                    $this->getTarget()->getTable()
                ]);
                sort($tablesNames);
                $this->_junctionTableName = implode('_', $tablesNames);
            }

            return $this->_junctionTableName;
        }

        return $this->_junctionTableName = $name;
    }
protected function _junctionTableName($name = null)
    {
        if ($name === null) {
            if (empty($this->_junctionTableName)) {
                $tablesNames = array_map('Cake\Utility\Inflector::underscore', [
                    $this->getSource()->getTable(),
                    $this->getTarget()->getTable()
                ]);
                sort($tablesNames);
                $this->_junctionTableName = implode('_', $tablesNames);
            }

            return $this->_junctionTableName;
        }

        return $this->_junctionTableName = $name;
    }
protected function _junctionTableName ( $ name = null ) { if ( $ name === null ) { if ( empty ( $ this -> _junctionTableName ) ) { $ tablesNames = array_map ( 'Cake\Utility\Inflector::underscore' , [ $ this -> getSource ( ) -> getTable ( ) , $ this -> getTarget ( ) -> getTable ( ) ] ) ; sort ( $ tablesNames ) ; $ this -> _junctionTableName = implode ( '_' , $ tablesNames ) ; } return $ this -> _junctionTableName ; } return $ this -> _junctionTableName = $ name ; }
Sets the name of the junction table.
If no arguments are passed the current configured name is returned. A default
name based of the associated tables will be generated if none found.

@param string|null $name The name of the junction table.
@return string
Sets the name of the junction table . If no arguments are passed the current configured name is returned . A default name based of the associated tables will be generated if none found .