Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
doctrine-dbal
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tomáš Trávníček
doctrine-dbal
Commits
e67b3070
Commit
e67b3070
authored
Aug 04, 2009
by
romanb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[2.0] Changed init() to __construct().
parent
aa0792b1
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
9 additions
and
10 deletions
+9
-10
Parser.php
lib/Doctrine/ORM/Query/Parser.php
+5
-6
SqlWalker.php
lib/Doctrine/ORM/Query/SqlWalker.php
+1
-1
TreeWalker.php
lib/Doctrine/ORM/Query/TreeWalker.php
+1
-1
TreeWalkerAdapter.php
lib/Doctrine/ORM/Query/TreeWalkerAdapter.php
+1
-1
LanguageRecognitionTest.php
tests/Doctrine/Tests/ORM/Query/LanguageRecognitionTest.php
+1
-1
No files found.
lib/Doctrine/ORM/Query/Parser.php
View file @
e67b3070
...
...
@@ -21,10 +21,10 @@
namespace
Doctrine\ORM\Query
;
use
Doctrine\Common\DoctrineException
;
use
Doctrine\ORM\Query
;
use
Doctrine\ORM\Query\AST
;
use
Doctrine\ORM\Query\Exec
;
use
Doctrine\Common\DoctrineException
,
Doctrine\ORM\Query
,
Doctrine\ORM\Query\AST
,
Doctrine\ORM\Query\Exec
;
/**
* An LL(*) parser for the context-free grammar of the Doctrine Query Language.
...
...
@@ -257,8 +257,7 @@ class Parser
}
// Create TreeWalker who creates the SQL from the AST
$treeWalker
=
$this
->
_treeWalker
?:
new
SqlWalker
();
$treeWalker
->
init
(
$treeWalker
=
$this
->
_treeWalker
?:
new
SqlWalker
(
$this
->
_query
,
$this
->
_parserResult
,
$this
->
_queryComponents
);
...
...
lib/Doctrine/ORM/Query/SqlWalker.php
View file @
e67b3070
...
...
@@ -74,7 +74,7 @@ class SqlWalker implements TreeWalker
/**
* @inheritdoc
*/
public
function
ini
t
(
$query
,
$parserResult
,
array
$queryComponents
)
public
function
__construc
t
(
$query
,
$parserResult
,
array
$queryComponents
)
{
$this
->
_rsm
=
$parserResult
->
getResultSetMapping
();
$this
->
_query
=
$query
;
...
...
lib/Doctrine/ORM/Query/TreeWalker.php
View file @
e67b3070
...
...
@@ -36,7 +36,7 @@ interface TreeWalker
* @param ParserResult $parserResult The result of the parsing process.
* @param array $queryComponents Query components (symbol table)
*/
function
ini
t
(
$query
,
$parserResult
,
array
$queryComponents
);
function
__construc
t
(
$query
,
$parserResult
,
array
$queryComponents
);
/**
* Walks down a SelectStatement AST node, thereby generating the appropriate SQL.
...
...
lib/Doctrine/ORM/Query/TreeWalkerAdapter.php
View file @
e67b3070
...
...
@@ -33,7 +33,7 @@ abstract class TreeWalkerAdapter implements TreeWalker
/**
* @inheritdoc
*/
public
function
ini
t
(
$query
,
$parserResult
,
array
$queryComponents
)
{}
public
function
__construc
t
(
$query
,
$parserResult
,
array
$queryComponents
)
{}
/**
* Walks down a SelectStatement AST node, thereby generating the appropriate SQL.
...
...
tests/Doctrine/Tests/ORM/Query/LanguageRecognitionTest.php
View file @
e67b3070
...
...
@@ -48,7 +48,7 @@ class LanguageRecognitionTest extends \Doctrine\Tests\OrmTestCase
$parser
=
new
\Doctrine\ORM\Query\Parser
(
$query
);
// We do NOT test SQL construction here. That only unnecessarily slows down the tests!
$parser
->
setTreeWalker
(
new
\Doctrine\Tests\Mocks\MockTreeWalker
);
$parser
->
setTreeWalker
(
new
\Doctrine\Tests\Mocks\MockTreeWalker
(
null
,
null
,
array
())
);
return
$parser
->
parse
();
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment