public function prepareQuery(Query $query)
    {
        $parameters = new Parameters($this->driver);

        if ($this->pdo === null)
            $this->connect();

        $sql = $this->driver->toSQL($parameters, $query);

        $statement = $this->prepare($sql);
        $parameters->bindParameters($statement);
        return $statement;
    }
public function prepareQuery(Query $query)
    {
        $parameters = new Parameters($this->driver);

        if ($this->pdo === null)
            $this->connect();

        $sql = $this->driver->toSQL($parameters, $query);

        $statement = $this->prepare($sql);
        $parameters->bindParameters($statement);
        return $statement;
    }
public function prepareQuery ( Query $ query ) { $ parameters = new Parameters ( $ this -> driver ) ; if ( $ this -> pdo === null ) $ this -> connect ( ) ; $ sql = $ this -> driver -> toSQL ( $ parameters , $ query ) ; $ statement = $ this -> prepare ( $ sql ) ; $ parameters -> bindParameters ( $ statement ) ; return $ statement ; }
Prepare a query and return the PDOStatement

@param Wedeto\DB\Query\Query The query to prepare
@return PDOStatement The prepared statement
Prepare a query and return the PDOStatement