Skip to content

Loading…

DDC-492: Doctrine\ORM\Query\TreeWalkerAdapter needs to provide access to private $_query member #4997

Closed
doctrinebot opened this Issue · 3 comments

2 participants

@doctrinebot

Jira issue originally created by user @hobodave:

I've been working on a pagination implementation that works properly for fetch-joined relations. To do this, I've been working with custom tree walkers.

I hit a roadblock when I needed access to the query hints from within my concrete TreeWalker. Since they are not in the AST, the only way to get at them is through the Query object. However, this is private on TreeWalkerAdapter, and cannot be accessed.

I propose adding a protected _getQuery() method to TreeWalkerAdapter to facilitate this.

@doctrinebot

Comment created by @hobodave:

Obviously this is trivial to implement, so I can commit what I have. If tests are needed I'll need to write those however. I usually don't test trivial, protected accessors.

@doctrinebot

Comment created by @beberlei:

Implemented, also allowed access to ParserResult.

@doctrinebot

Issue was closed with resolution "Fixed"

@beberlei beberlei was assigned by doctrinebot
@doctrinebot doctrinebot added this to the 2.0-BETA1 milestone
@doctrinebot doctrinebot closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.