Execute strainer

@param \FrenchFrogs\Table\Table\Table $table
@param array ...$params
@return $this
@throws \Exception
516103
public function call(\FrenchFrogs\Table\Table\Table $table, ...$params)
    {

        if ($this->hasCallable()) {
            array_unshift($params, $this);
            array_unshift($params, $table);
            call_user_func_array($this->callable, $params);
        } else {

            // verify that source is a query
            if (!$table->isSourceQueryBuilder()) {
                throw new \Exception('Table source is not an instance of query builder');
            }

            $this->setValue($params[0]);
            $table->getSource()->where($this->getField(), '=', $params[0]);
        }

        return $this;
    }
752986
public function execute(array $params = null)
    {
        $this->bindParams($params);
        $this->formatSqlByParams($params);
        $result = $this->stmt->execute();

        if ($result !== true) {
            throw new MysqlException('Sync mysql execute error，sql=' . $this->stmt->debugDumpParams());
        }
        $this->pushSqlToStack($this->sql);

        return $result;
    }
919669
public function execute(array $params = []): Promise
    {
        $this->lastUsedAt = \time();

        return call(function () use ($params) {
            $statement = yield from $this->pop();
            \assert($statement instanceof Statement);

            try {
                $statement = yield $this->prepare($statement);
                \assert($statement instanceof Statement);
                $result = yield $statement->execute($params);
            } catch (\Throwable $exception) {
                $this->push($statement);
                throw $exception;
            }

            if ($result instanceof ResultSet) {
                $result = $this->createResultSet($result, function () use ($statement) {
                    $this->push($statement);
                });
            } else {
                $this->push($statement);
            }

            return $result;
        });
    }
1273079
public function execute($sql, $params = null)
    {
        $stmt = $this->_pdo->prepare($sql);

        if (is_array($params)) {
            foreach ($params as $token => $value) {
                $stmt->bindValue($token, $value);
            }
        }

        try {
            $stmt->execute();
        } catch (PDOException $exception) {
            $this->_database->error('execute', $exception);
        }

        return $stmt;
    }
1269570
public function initialize(Table $table)
    {
        $this->table = $table;
        $this->table->isProcessing(true);
        $this->table->isServerSide(true);

        if (!is_null($this->ajax)) {
            $this->table->setAjax($this->ajax);
        }
    }
746051
protected function checkTable($table)
    {
        try {
            $this->Table = $this->loadModel($table);
        } catch (Exception $e) {
            $this->out(__('<error>' . $e->getMessage() . '</error>'));
            $this->_stop();
        }

        if (get_class($this->Table) === 'AppModel') {
            $this->out(__('<error>The table could not be found, instance of AppModel loaded.</error>'));
            $this->_stop();
        }

        if (!$this->Table->hasBehavior('Proffer')) {
            $out = __(
                "<error>The table '" . $this->Table->alias() .
                "' does not have the Proffer behavior attached.</error>"
            );
            $this->out($out);
            $this->_stop();
        }

        $config = $this->Table->behaviors()->Proffer->config();
        foreach ($config as $field => $settings) {
            if (!$this->Table->hasField($field)) {
                $out = __(
                    "<error>The table '" . $this->Table->alias() .
                    "' does not have the configured upload field in it's schema.</error>"
                );
                $this->out($out);
                $this->_stop();
            }
            if (!$this->Table->hasField($settings['dir'])) {
                $out = __(
                    "<error>The table '" . $this->Table->alias() .
                    "' does not have the configured dir field in it's schema.</error>"
                );
                $this->out($out);
                $this->_stop();
            }
        }

        if ($this->param('remove-behaviors')) {
            $removeBehaviors = explode(',', (string)$this->param('remove-behaviors'));
            foreach ($removeBehaviors as $removeBehavior) {
                $this->Table->removeBehavior($removeBehavior);
            }
        }
    }
1128530
public function setTable($table)
    {
        $this->table = 'post_'.cleanPostTypeSlug($table);
        self::$_tmptable = $this->table;
        return $this;
    }
1162153
public function rowsFrom(string $table, string ...$tables)
    {
        $instance = $this->deleteQueryInstance();

        $instance->deleteQuery()->rowsFrom($table, ...$tables);

        return $instance;
    }
983984
public function the_plugins_should_be( TableNode $table )
	{
		foreach ( $table->getHash() as $row ) {
			$slug = $row['slug'];
			$expect = $row['status'];
			if ( ! $this->is_plugin_installed( $slug ) ) {
				throw new \Exception( sprintf(
					"The %s plugin is not installed.",
					$slug
				) );
			}
			if ( "active" === $expect && ! $this->is_plugin_activated( $slug ) ) {
				throw new \Exception( sprintf(
					"The %s plugin should be activated, but not activated.",
					$slug
				) );
			} elseif ( "inactive" === $expect && $this->is_plugin_activated( $slug ) ) {
				throw new \Exception( sprintf(
					"The %s plugin should not be activated, but activated.",
					$slug
				) );
			} elseif ( "active" !== $expect && "inactive" !== $expect ) {
				throw new \Exception( sprintf(
					"Incorrect status: %s",
					$expect
				) );
			}
		}
	}
547189
public function table($table)
    {
        $tables = is_array($table) ? $table : func_get_args();
        $this->_parts['table'] = $tables;
        return $this;
    }
1055311
public function table($table = '', $tablePrefix = null)
    {
        $hasAlias = is_array($table) ? true : false;
        is_null($tablePrefix) && $tablePrefix = $this->tablePrefix;
        $tableName = $tablePrefix . ($hasAlias ? key($table) : $table);

        $this->table[count($this->table) . '_' . $tableName] = $hasAlias ? current($table) : null;
        return $this;
    }
18761
public function insert($table, $columns, array $params = [])
    {
        $request = $this->db->getQueryBuilder()->insert($table, $columns, $params);

        return $this->setRequest($request);
    }
685250
public function from($table, ...$tables)
    {
        $instance = $this->fromStrategyInstance();

        $instance->fromStrategy()->from($table, ...$tables);

        return $instance;
    }
176651
public function setTable($table)
    {
        $this->table = $table;

        //for each row
        foreach ($this->data as $row) {
            if (!is_object($row) || !method_exists($row, __FUNCTION__)) {
                continue;
            }

            //let the row handle this
            $row->setTable($table);
        }

        return $this;
    }
1114681
protected function validateTable($table)
    {
        $this->checkTableArgument($table);
        if (!$this->hasTable($table)) {
            throw new Exception\TableNotFoundException(__METHOD__ . ": Table '$table' does not exists in database '{$this->schema}'");
        }

        return $this;
    }
276409
public function table($table)
	{
		if($table instanceof Closure)
		{
			$table = new Subquery($table, 'mako0');
		}

		$this->table = $table;

		return $this;
	}
1319827
protected function invoke($controller, $method, $params)
    {
        if (!class_exists($controller)) {
            throw new Exception("Controller [ $controller ] does not exist.");
        }

        try {
            $instance = $this->container->make($controller);

            $resolving = $this->container->resolveMethod($controller, $method, $params, true);

            $this->validateForm($resolving);

            return call_user_func_array([$instance, $method], $resolving);
        } catch (DefinitionException $e) {
            throw new BindingException("Binding Error [ ". $e->getMessage() ." ]");
        }

    }