RSI helpers  0.1
RSI helpers
Query Class Reference

Simple query builder. More...

Inheritance diagram for Query:
Thing

Public Member Functions

 __construct ($table)
 
 select ($column)
 
 join ($join, $outer=false)
 
 where ($condition)
 
 group ($group)
 
 having ($condition)
 
 order ($order)
 
 limit ($limit, $offset=0)
 
 arg ($key, $value)
 
 args ($values=null)
 
 __toString ()
 
- Public Member Functions inherited from Thing
 propertyExists ($property)
 Check if a property exists (public or published). More...
 
 constants ($prefix=null)
 Return all constants. More...
 
 get ($key)
 Get one or more properties. More...
 
 set ($key, $value=null)
 Set one or more properties. More...
 
 __get ($key)
 
 __set ($key, $value)
 

Protected Member Functions

 getArgs ()
 
 setArgs ($value)
 
 getSql ()
 
 _set ($key, $value)
 
 _get ($key)
 
- Protected Member Functions inherited from Thing
 publish ($property, $visibility=self::READABLE)
 Publish a property (or hide it again). More...
 
 configure ($config)
 Configure the object. More...
 
 _get ($key)
 Default getter if no specific setter is defined, and the property is also not published (readable). More...
 
 _set ($key, $value)
 Default setter if no specific setter is defined, and the property is also not published (writeable). More...
 

Protected Attributes

 $_select = []
 
 $_tables = []
 
 $_where = []
 
 $_group = []
 
 $_having = []
 
 $_order = []
 
 $_limit = null
 
 $_offset = null
 
 $_args = []
 
- Protected Attributes inherited from Thing
 $_published = []
 Published properties (key = name of property, value = visibility). More...
 

Additional Inherited Members

- Data Fields inherited from Thing
const HIDDEN = 0
 Property is hidden. More...
 
const READABLE = 1
 Property is readable. More...
 
const WRITEABLE = 2
 Property is writeable. More...
 
const READWRITE = 3
 Property is readable and writeable. More...
 

Detailed Description

Simple query builder.

Definition at line 8 of file Query.php.

Constructor & Destructor Documentation

◆ __construct()

__construct (   $table)

Definition at line 20 of file Query.php.

Member Function Documentation

◆ __toString()

__toString ( )

Definition at line 97 of file Query.php.

◆ _get()

_get (   $key)
protected

Definition at line 93 of file Query.php.

◆ _set()

_set (   $key,
  $value 
)
protected

Definition at line 89 of file Query.php.

◆ arg()

arg (   $key,
  $value 
)

Definition at line 60 of file Query.php.

◆ args()

args (   $values = null)

Definition at line 65 of file Query.php.

◆ getArgs()

getArgs ( )
protected

Definition at line 70 of file Query.php.

◆ getSql()

getSql ( )
protected

Definition at line 78 of file Query.php.

◆ group()

group (   $group)

Definition at line 39 of file Query.php.

◆ having()

having (   $condition)

Definition at line 44 of file Query.php.

◆ join()

join (   $join,
  $outer = false 
)

Definition at line 29 of file Query.php.

◆ limit()

limit (   $limit,
  $offset = 0 
)

Definition at line 54 of file Query.php.

◆ order()

order (   $order)

Definition at line 49 of file Query.php.

◆ select()

select (   $column)

Definition at line 24 of file Query.php.

◆ setArgs()

setArgs (   $value)
protected

Definition at line 74 of file Query.php.

◆ where()

where (   $condition)

Definition at line 34 of file Query.php.

Field Documentation

◆ $_args

$_args = []
protected

Definition at line 18 of file Query.php.

◆ $_group

$_group = []
protected

Definition at line 13 of file Query.php.

◆ $_having

$_having = []
protected

Definition at line 14 of file Query.php.

◆ $_limit

$_limit = null
protected

Definition at line 16 of file Query.php.

◆ $_offset

$_offset = null
protected

Definition at line 17 of file Query.php.

◆ $_order

$_order = []
protected

Definition at line 15 of file Query.php.

◆ $_select

$_select = []
protected

Definition at line 10 of file Query.php.

◆ $_tables

$_tables = []
protected

Definition at line 11 of file Query.php.

◆ $_where

$_where = []
protected

Definition at line 12 of file Query.php.


The documentation for this class was generated from the following file: