本文整理汇总了PHP中Doctrine\ORM\EntityManagerInterface::getExpressionBuilder方法的典型用法代码示例。如果您正苦于以下问题:PHP EntityManagerInterface::getExpressionBuilder方法的具体用法?PHP EntityManagerInterface::getExpressionBuilder怎么用?PHP EntityManagerInterface::getExpressionBuilder使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Doctrine\ORM\EntityManagerInterface
的用法示例。
在下文中一共展示了EntityManagerInterface::getExpressionBuilder方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: expr
/**
* Gets an ExpressionBuilder used for object-oriented construction of query expressions.
* This producer method is intended for convenient inline usage. Example:
*
* <code>
* $qb = $em->createQueryBuilder();
* $qb
* ->select('u')
* ->from('User', 'u')
* ->where($qb->expr()->eq('u.id', 1));
* </code>
*
* For more complex expression construction, consider storing the expression
* builder object in a local variable.
*
* @return Query\Expr
*/
public function expr()
{
return $this->_em->getExpressionBuilder();
}
示例2: getExpressionBuilder
/**
* {@inheritdoc}
*/
public function getExpressionBuilder()
{
return $this->wrapped->getExpressionBuilder();
}