src/Aggregator/Configuration.php
public function setJoinData(Table $table, EntityInterface $entity) : self
    {
        $entityClass = $table->getEntityClass();
        if (! $entity instanceof $entityClass) {
            throw new InvalidArgumentException(sprintf(
                'Entity must be an instance of "%s". Instead, instance of "%s" was provided.',
                $table->getEntityClass(),
                get_class($entity)
            ));
        }

        $this->joinTable = $table;
        $this->entity = $entity;

        return $this;
    }
public function setJoinData(Table $table, EntityInterface $entity) : self
    {
        $entityClass = $table->getEntityClass();
        if (! $entity instanceof $entityClass) {
            throw new InvalidArgumentException(sprintf(
                'Entity must be an instance of "%s". Instead, instance of "%s" was provided.',
                $table->getEntityClass(),
                get_class($entity)
            ));
        }

        $this->joinTable = $table;
        $this->entity = $entity;

        return $this;
    }
public function setJoinData ( Table $ table , EntityInterface $ entity ) : self { $ entityClass = $ table -> getEntityClass ( ) ; if ( ! $ entity instanceof $ entityClass ) { throw new InvalidArgumentException ( sprintf ( 'Entity must be an instance of "%s". Instead, instance of "%s" was provided.' , $ table -> getEntityClass ( ) , get_class ( $ entity ) ) ) ; } $ this -> joinTable = $ table ; $ this -> entity = $ entity ; return $ this ; }
Join data setter.

@param \Cake\ORM\Table $table Join table intsance
@param \Cake\Datasource\EntityInterface $entity Entity instance from join table
@return self
Join data setter .