Doctrine


Doctrine\ORM\Query\ParserResult
/Doctrine/ORM/Query/ParserResult.php at line 36

Class ParserResult

ParserResult

public class ParserResult

Encapsulates the resulting components from a DQL query parsing process that can be serialized.

Author:
Guilherme Blanco
Janne Vanhala
Author Roman:
Borschel
License:
http://www.opensource.org/licenses/lgpl-license.php LGPL
See Also:
http://www.doctrine-project.org
Since:
2.0
Version:
$Revision$

Constructor Summary

ParserResult()

Initializes a new instance of the ParserResult class.

Method Summary
void

addParameterMapping(string|integer dqlPosition, integer sqlPosition)

Adds a DQL to SQL parameter mapping.

array

getParameterMappings()

Gets all DQL to SQL parameter mappings.

ResultSetMapping

getResultSetMapping()

Gets the ResultSetMapping for the parsed query.

\Doctrine\ORM\Query\Exec\AbstractSqlExecutor

getSqlExecutor()

Gets the SQL executor used by this ParserResult.

array

getSqlParameterPositions(string|integer dqlPosition)

Gets the SQL parameter positions for a DQL parameter name/position.

void

setResultSetMapping(ResultSetMapping rsm)

Sets the ResultSetMapping of the parsed query.

void

setSqlExecutor(\Doctrine\ORM\Query\Exec\AbstractSqlExecutor executor)

Sets the SQL executor that should be used for this ParserResult.

Constructor Detail

/Doctrine/ORM/Query/ParserResult.php at line 63

ParserResult

public ParserResult()

Initializes a new instance of the ParserResult class. The new instance is initialized with an empty ResultSetMapping.


Method Detail

/Doctrine/ORM/Query/ParserResult.php at line 116

addParameterMapping

public void addParameterMapping(string|integer dqlPosition, integer sqlPosition)

Adds a DQL to SQL parameter mapping. One DQL parameter name/position can map to several SQL parameter positions.


/Doctrine/ORM/Query/ParserResult.php at line 126

getParameterMappings

public array getParameterMappings()

Gets all DQL to SQL parameter mappings.

Returns:
The parameter mappings.

/Doctrine/ORM/Query/ParserResult.php at line 74

getResultSetMapping

public ResultSetMapping getResultSetMapping()

Gets the ResultSetMapping for the parsed query.

Returns:
The result set mapping of the parsed query or NULL if the query is not a SELECT query.

/Doctrine/ORM/Query/ParserResult.php at line 104

getSqlExecutor

public \Doctrine\ORM\Query\Exec\AbstractSqlExecutor getSqlExecutor()

Gets the SQL executor used by this ParserResult.


/Doctrine/ORM/Query/ParserResult.php at line 137

getSqlParameterPositions

public array getSqlParameterPositions(string|integer dqlPosition)

Gets the SQL parameter positions for a DQL parameter name/position.

Parameters:
dqlPosition - The name or position of the DQL parameter.
Returns:
The positions of the corresponding SQL parameters.

/Doctrine/ORM/Query/ParserResult.php at line 84

setResultSetMapping

public void setResultSetMapping(ResultSetMapping rsm)

Sets the ResultSetMapping of the parsed query.


/Doctrine/ORM/Query/ParserResult.php at line 94

setSqlExecutor

public void setSqlExecutor(\Doctrine\ORM\Query\Exec\AbstractSqlExecutor executor)

Sets the SQL executor that should be used for this ParserResult.


Doctrine