protected function _generateJunctionAssociations($junction, $source, $target)
{
$tAlias = $target->alias();
$sAlias = $source->alias();
if (!$junction->association($tAlias)) {
$junction->belongsTo($tAlias, ['foreignKey' => $this->targetForeignKey(), 'targetTable' => $target]);
}
if (!$junction->association($sAlias)) {
$junction->belongsTo($sAlias, ['foreignKey' => $this->foreignKey(), 'targetTable' => $source]);
}
}