Overview

Namespaces

  • None
  • Xmf
    • Database
    • Module
      • Helper
    • Template
  • Xoops
    • Auth
    • Core
      • Cache
      • Database
        • Logging
        • Schema
      • Exception
      • Handler
        • Scheme
      • Kernel
        • Dtype
        • Handlers
        • Model
      • Lists
      • Locale
        • Punic
      • Service
        • Contract
      • Session
      • Text
        • Sanitizer
          • Extensions
      • Theme
        • Plugins
    • Form
    • Html
    • Locale
    • Module
      • Helper
      • Plugin

Classes

  • Criteria
  • CriteriaCompo
  • CriteriaElement
  • Dtype
  • XoopsModelAbstract
  • XoopsModelFactory
  • XoopsObject
  • XoopsObjectHandler
  • XoopsPersistableObjectHandler
  • Overview
  • Namespace
  • Class
  • Tree

Class Criteria

A single criteria for database query

Xoops\Core\Kernel\CriteriaElement
Extended by Xoops\Core\Kernel\Criteria

Direct known subclasses

Criteria
Namespace: Xoops\Core\Kernel
Package: Xoops\Core\Kernel
Category: Xoops\Core\Kernel\Criteria
Copyright: 2000-2013 XOOPS Project (http://xoops.org)
License: GPL 2 or later (http://www.gnu.org/licenses/gpl-2.0.html)
Author: Kazumi Ono onokazu@xoops.org
Author: Nathan Dial ndial@trillion21.com
Author: Taiwen Jiang phppp@users.sourceforge.net
Since: 2.0.0
Link: http://xoops.org
Located at oops_lib/Xoops/Core/Kernel/Criteria.php
Methods summary
public
# __construct( string $column, string $value = '', string $operator = '=', string $prefix = '', string $function = '' )

Constructor

Constructor

Parameters

$column
column criteria applies to
$value
value to compare to column
$operator
operator to apply to column
$prefix
prefix to append to column
$function
sprintf string taking one string argument applied to column
public string
# render( )

Make a sql condition string

Make a sql condition string

Returns

string
public string
# renderLdap( )

Generate an LDAP filter from criteria

Generate an LDAP filter from criteria

Returns

string

Author

Nathan Dial ndial@trillion21.com, improved by Pierre-Eric MENUET pemen@sourceforge.net
public string
# renderWhere( )

Make a SQL "WHERE" clause

Make a SQL "WHERE" clause

Returns

string
public Doctrine\DBAL\Query\QueryBuilder
# renderQb( Doctrine\DBAL\Query\QueryBuilder $qb = null, string $whereMode = '' )

Render criteria as Doctrine QueryBuilder instructions

Render criteria as Doctrine QueryBuilder instructions

Parameters

$qb
query builder instance
$whereMode

how does this fit in the passed in QueryBuilder? '' = as where,'and'= as andWhere, 'or' = as orWhere

Returns

Doctrine\DBAL\Query\QueryBuilder
query builder instance
public string
# buildExpressionQb( Doctrine\DBAL\Query\QueryBuilder $qb )

Build an expression to be included in a Doctrine QueryBuilder instance.

Build an expression to be included in a Doctrine QueryBuilder instance.

This method will build an expression, adding any parameters to the query, but the caller is responsible for adding the expression to the query, for example as where() parameter. This allows the caller to handle all context, such as parenthetical groupings.

Parameters

$qb
query builder instance

Returns

string
expression
Methods inherited from Xoops\Core\Kernel\CriteriaElement
getGroupBy(), getLimit(), getOrder(), getSort(), getStart(), setGroupBy(), setLimit(), setOrder(), setSort(), setStart()
Properties summary
public string $prefix
#
public string $function
#
public string $column
#
public string $operator
#
public mixed $value
#
Properties inherited from Xoops\Core\Kernel\CriteriaElement
$groupBy, $limit, $order, $sort, $start
API documentation generated by ApiGen