diff --git a/docs/classes/Query.Abstract_Query_Builder.html b/docs/classes/Query.Abstract_Query_Builder.html new file mode 100644 index 0000000..609cd2c --- /dev/null +++ b/docs/classes/Query.Abstract_Query_Builder.html @@ -0,0 +1,1644 @@ + + + + + + Query + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+
+
+
+ + + +

\QueryAbstract_Query_Builder

+

Abstract Class for internal implementation methods of the Query Builder

+ + +
+

Summary

+
+
+ Methods +
+
+ Properties +
+
+ Constants +
+
+
+
+ __call()
+
+
+ $conn_name
+ $queries
+
+
+ No constants found +
+
+
+
+ _select()
+ _get_compile()
+ _like()
+ _having()
+ _where()
+ _where_string()
+ _where_in()
+ _run()
+ _append_map()
+ _append_query()
+ _compile_type()
+ _compile()
+
+
+ $select_string
+ $from_string
+ $set_string
+ $order_string
+ $group_string
+ $set_array_keys
+ $order_array
+ $group_array
+ $values
+ $where_values
+ $limit
+ $offset
+ $query_map
+ $having_map
+ $explain
+
+
+ N/A +
+
+
+
+ No private methods found +
+
+ No private properties found +
+
+ N/A +
+
+
+
+ +
+ + + +
+
+

Properties

+
+ +
+ +
+
+ +
+

$conn_name

+
$conn_name : string
+

Convenience property for connection management

+ + +

Type

+ string +
+
+ +
+ +
+
+ +
+

$queries

+
$queries : array
+

List of queries executed

+ + +

Type

+ array +
+
+ +
+ +
+
+ +
+

$select_string

+
$select_string : string
+

Compiled 'select' clause

+ + +

Type

+ string +
+
+ +
+ +
+
+ +
+

$from_string

+
$from_string : string
+

Compiled 'from' clause

+ + +

Type

+ string +
+
+ +
+ +
+
+ +
+

$set_string

+
$set_string : string
+

Compiled arguments for insert / update

+ + +

Type

+ string +
+
+ +
+ +
+
+ +
+

$order_string

+
$order_string : string
+

Order by clause

+ + +

Type

+ string +
+
+ +
+ +
+
+ +
+

$group_string

+
$group_string : string
+

Group by clause

+ + +

Type

+ string +
+
+ +
+ +
+
+ +
+

$set_array_keys

+
$set_array_keys : array
+

Keys for insert/update statement

+ + +

Type

+ array +
+
+ +
+ +
+
+ +
+

$order_array

+
$order_array : array
+

Key/val pairs for order by clause

+ + +

Type

+ array +
+
+ +
+ +
+
+ +
+

$group_array

+
$group_array : array
+

Key/val pairs for group by clause

+ + +

Type

+ array +
+
+ +
+ +
+
+ +
+

$values

+
$values : array
+

Values to apply to prepared statements

+ + +

Type

+ array +
+
+ +
+ +
+
+ +
+

$where_values

+
$where_values : array
+

Values to apply to where clauses in prepared statements

+ + +

Type

+ array +
+
+ +
+ +
+
+ +
+

$limit

+
$limit : string
+

Value for limit string

+ + +

Type

+ string +
+
+ +
+ +
+
+ +
+

$offset

+
$offset : int
+

Value for offset in limit string

+ + +

Type

+ int +
+
+ +
+ +
+
+ +
+

$query_map

+
$query_map : array
+

Query component order mapping +for complex select queries

+

Format: +array(

+
'type' => 'where',
+'conjunction' => ' AND ',
+'string' => 'k=?'
+

)

+ +

Type

+ array +
+
+ +
+ +
+
+ +
+

$having_map

+
$having_map : array
+

Map for having clause

+ + +

Type

+ array +
+
+ +
+ +
+
+ +
+

$explain

+
$explain : bool
+

Whether to do only an explain on the query

+ + +

Type

+ bool +
+
+ +
+ + + +
+

Methods

+ +
+ +
+
+ +
+

__call()

+ +
__call(string $name, array $params) : mixed
+

Calls a function further down the inheritence chain

+ + +

Parameters

+ + + + + + + + + + + +
string$name
array$params
+ +

Throws

+
+
\BadMethodCallException
+
+
+ +

Returns

+ mixed +
+
+ +
+ +
+
+ +
+

_select()

+ +
_select(string $field, string|bool $as) : string
+

Method to simplify select_ methods

+ + +

Parameters

+ + + + + + + + + + + +
string$field
string|bool$as
+ + +

Returns

+ string +
+
+ +
+ +
+
+ +
+

_get_compile()

+ +
_get_compile(string $type, string $table, bool $reset) : string
+

Helper function for returning sql strings

+ + +

Parameters

+ + + + + + + + + + + + + + + + +
string$type
string$table
bool$reset
+ + +

Returns

+ string +
+
+ +
+ +
+
+ +
+

_like()

+ +
_like(string $field, mixed $val, string $pos, string $like, string $conj) : \Query\Query_Builder
+

Simplify 'like' methods

+ + +

Parameters

+ + + + + + + + + + + + + + + + + + + + + + + + + + +
string$field
mixed$val
string$pos
string$like
string$conj
+ + +

Returns

+ \Query\Query_Builder +
+
+ +
+ +
+
+ +
+

_having()

+ +
_having(mixed $key, mixed $val, string $conj) : \Query\Query_Builder
+

Simplify building having clauses

+ + +

Parameters

+ + + + + + + + + + + + + + + + +
mixed$key
mixed$val
string$conj
+ + +

Returns

+ \Query\Query_Builder +
+
+ +
+ +
+
+ +
+

_where()

+ +
_where(mixed $key, mixed $val) : array
+

Do all the repeditive stuff for where/having type methods

+ + +

Parameters

+ + + + + + + + + + + +
mixed$key
mixed$val
+ + +

Returns

+ array +
+
+ +
+ +
+
+ +
+

_where_string()

+ +
_where_string(mixed $key, mixed $val, string $conj) : \Query\Query_Builder
+

Simplify generating where string

+ + +

Parameters

+ + + + + + + + + + + + + + + + +
mixed$key
mixed$val
string$conj
+ + +

Returns

+ \Query\Query_Builder +
+
+ +
+ +
+
+ +
+

_where_in()

+ +
_where_in(mixed $key, mixed $val, string $in, string $conj) : \Query\Query_Builder
+

Simplify where_in methods

+ + +

Parameters

+ + + + + + + + + + + + + + + + + + + + + +
mixed$key
mixed$val
string$in
    +
  • The (not) in fragment
  • +
string$conj
    +
  • The where in conjunction
  • +
+ + +

Returns

+ \Query\Query_Builder +
+
+ +
+ +
+
+ +
+

_run()

+ +
_run(string $type, string $table, string $sql, array|null $vals) : \PDOStatement
+

Executes the compiled query

+ + +

Parameters

+ + + + + + + + + + + + + + + + + + + + + +
string$type
string$table
string$sql
array|null$vals
+ + +

Returns

+ \PDOStatement +
+
+ +
+ +
+
+ +
+

_append_map()

+ +
_append_map(string $conjunction, string $string, string $type) : void
+

Add an additional set of mapping pairs to a internal map

+ + +

Parameters

+ + + + + + + + + + + + + + + + +
string$conjunction
string$string
string$type
+ + +
+
+ +
+ +
+
+ +
+

_append_query()

+ +
_append_query(array $vals, string $sql, string $total_time) : void
+

Convert the prepared statement into readable sql

+ + +

Parameters

+ + + + + + + + + + + + + + + + +
array$vals
string$sql
string$total_time
+ + +
+
+ +
+ +
+
+ +
+

_compile_type()

+ +
_compile_type(string $type, string $table) : string
+

Sub-method for generating sql strings

+ + +

Parameters

+ + + + + + + + + + + +
string$type
string$table
+ + +

Returns

+ string +
+
+ +
+ +
+
+ +
+

_compile()

+ +
_compile(string $type, string $table) : \Query\$string
+

String together the sql statements for sending to the db

+ + +

Parameters

+ + + + + + + + + + + +
string$type
string$table
+ + +

Returns

+ \Query\$string +
+
+ +
+ +
+
+ + + + +
+ + + diff --git a/docs/classes/Query.BadDBDriverException.html b/docs/classes/Query.BadDBDriverException.html index 3abd5d9..acd4e64 100644 --- a/docs/classes/Query.BadDBDriverException.html +++ b/docs/classes/Query.BadDBDriverException.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -414,7 +415,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/classes/Query.Connection_Manager.html b/docs/classes/Query.Connection_Manager.html index 6182866..b042336 100644 --- a/docs/classes/Query.Connection_Manager.html +++ b/docs/classes/Query.Connection_Manager.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -838,7 +839,7 @@ Query method


Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/classes/Query.Driver.Abstract_Driver.html b/docs/classes/Query.Driver.Abstract_Driver.html index c468e37..45511d0 100644 --- a/docs/classes/Query.Driver.Abstract_Driver.html +++ b/docs/classes/Query.Driver.Abstract_Driver.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -331,7 +332,6 @@ $table
$last_query
$table_prefix
- $has_truncate
No constants found @@ -345,6 +345,7 @@
$statement
$escape_char
+ $has_truncate
N/A @@ -556,36 +557,6 @@
-
-
- -
-

$has_truncate

-
$has_truncate : bool
-

Whether the driver supports 'TRUNCATE'

- - -

Type

- bool -
-
- -
-
@@ -646,6 +617,36 @@
+
+
+ +
+

$has_truncate

+
$has_truncate : bool
+

Whether the driver supports 'TRUNCATE'

+ + +

Type

+ bool +
+
+ +
+
@@ -767,14 +768,14 @@

get_sql()

-
get_sql() : \Query\Driver\SQL_Interface
+
get_sql() : \Query\Driver\SQL\SQL_Interface

Get the SQL class for the current driver

Returns

- \Query\Driver\SQL_Interface + \Query\Driver\SQL\SQL_Interface
-
-
- -
-

$has_truncate

-
$has_truncate : bool
-

Whether the driver supports 'TRUNCATE'

- - -

Type

- bool -
-
- -
-
@@ -663,6 +632,38 @@
+
+
+ +
+

$has_truncate

+
$has_truncate : bool
+

Whether the driver supports 'TRUNCATE'

+ + +

Type

+ bool +
+
+ +
+
@@ -788,14 +789,14 @@

get_sql()

-
get_sql() : \Query\Driver\SQL_Interface
+
get_sql() : \Query\Driver\SQL\SQL_Interface

Get the SQL class for the current driver

Returns

- \Query\Driver\SQL_Interface + \Query\Driver\SQL\SQL_Interface
-
-
- -
-

$has_truncate

-
$has_truncate : bool
-

Whether the driver supports 'TRUNCATE'

- - -

Type

- bool -
-
- -
-
@@ -663,6 +632,38 @@
+
+
+ +
+

$has_truncate

+
$has_truncate : bool
+

Whether the driver supports 'TRUNCATE'

+ + +

Type

+ bool +
+
+ +
+
@@ -866,14 +867,14 @@

get_sql()

-
get_sql() : \Query\Driver\SQL_Interface
+
get_sql() : \Query\Driver\SQL\SQL_Interface

Get the SQL class for the current driver

Returns

- \Query\Driver\SQL_Interface + \Query\Driver\SQL\SQL_Interface
+
+
+ +
+

$conn_name

+
$conn_name : string
+

Convenience property for connection management

+ + +

Type

+ string +
+
+ +
+ +
+
+ +
+

$queries

+
$queries : array
+

List of queries executed

+ + +

Type

+ array +
+
+ +
+
+
+ +
+

$parser

+
$parser : \Query\Query_Parser
+

Query parser class instance

+ + +

Type

+ \Query\Query_Parser +
+
+ +
+ +
@@ -610,6 +647,8 @@ instantiates the specific db driver

-
- -
-
- -
-

$parser

-
$parser : \Query\Query_Parser
-

Query parser class instance

- - -

Type

- \Query\Query_Parser -
-
-
@@ -2294,7 +2337,13 @@ passed array with key / value pairs

Tags

- + + + +
None found
+ todo + +
@@ -3060,7 +3109,9 @@ in place of the get() method

+
+ +
+
+ +
+

_get_compile()

+ +
_get_compile(string $type, string $table, bool $reset) : string
+

Helper function for returning sql strings

+ + +

Parameters

+ + + + + + + + + + + + + + + + +
string$type
string$table
bool$reset
+ + +

Returns

+ string +
+
+ -
- -
-
- -
-

_get_compile()

- -
_get_compile(string $type, string $table, bool $reset) : string
-

Helper function for returning sql strings

- - -

Parameters

- - - - - - - - - - - - - - - - -
string$type
string$table
bool$reset
- - -

Returns

- string -
-
- -
- -
-
- -
-

_append_query()

- -
_append_query(array $vals, string $sql, string $total_time) : void
-

Convert the prepared statement into readable sql

- - -

Parameters

- - - - - - - - - - - - - - - - -
array$vals
string$sql
string$total_time
- - -
-
- +
+ +
+
+ +
+

_append_query()

+ +
_append_query(array $vals, string $sql, string $total_time) : void
+

Convert the prepared statement into readable sql

+ + +

Parameters

+ + + + + + + + + + + + + + + + +
array$vals
string$sql
string$total_time
+ + +
+
+
+ + +
+ + + +
+ + + + + +
+ + + diff --git a/docs/files/core.abstract.abstract_sql.php.html b/docs/files/core.abstract.abstract_sql.php.html index 2c52d04..7f430f2 100644 --- a/docs/files/core.abstract.abstract_sql.php.html +++ b/docs/files/core.abstract.abstract_sql.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.abstract.abstract_table.php.html b/docs/files/core.abstract.abstract_table.php.html index a7b32f3..b4f3712 100644 --- a/docs/files/core.abstract.abstract_table.php.html +++ b/docs/files/core.abstract.abstract_table.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.abstract.abstract_util.php.html b/docs/files/core.abstract.abstract_util.php.html index d707c7e..57bd289 100644 --- a/docs/files/core.abstract.abstract_util.php.html +++ b/docs/files/core.abstract.abstract_util.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.connection_manager.php.html b/docs/files/core.connection_manager.php.html index 8ac6fbd..cf9fdea 100644 --- a/docs/files/core.connection_manager.php.html +++ b/docs/files/core.connection_manager.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -388,7 +389,7 @@ Query method

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.interfaces.driver_interface.php.html b/docs/files/core.interfaces.driver_interface.php.html index 4bfbc25..6c41a4d 100644 --- a/docs/files/core.interfaces.driver_interface.php.html +++ b/docs/files/core.interfaces.driver_interface.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.interfaces.query_builder_interface.php.html b/docs/files/core.interfaces.query_builder_interface.php.html index 1cc5922..347594b 100644 --- a/docs/files/core.interfaces.query_builder_interface.php.html +++ b/docs/files/core.interfaces.query_builder_interface.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.interfaces.sql_interface.php.html b/docs/files/core.interfaces.sql_interface.php.html index 2c8d5be..a9f487a 100644 --- a/docs/files/core.interfaces.sql_interface.php.html +++ b/docs/files/core.interfaces.sql_interface.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.query_builder.php.html b/docs/files/core.query_builder.php.html index 559bdd7..332acad 100644 --- a/docs/files/core.query_builder.php.html +++ b/docs/files/core.query_builder.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -384,7 +385,7 @@ instantiates the specific db driver

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.query_parser.php.html b/docs/files/core.query_parser.php.html index 0dcc45f..d80a642 100644 --- a/docs/files/core.query_parser.php.html +++ b/docs/files/core.query_parser.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.table_builder.php.html b/docs/files/core.table_builder.php.html index cc6774a..3060f2b 100644 --- a/docs/files/core.table_builder.php.html +++ b/docs/files/core.table_builder.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.table_column.php.html b/docs/files/core.table_column.php.html index 9597db7..20545af 100644 --- a/docs/files/core.table_column.php.html +++ b/docs/files/core.table_column.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.table_foreign_key.php.html b/docs/files/core.table_foreign_key.php.html index f493057..3a45f5b 100644 --- a/docs/files/core.table_foreign_key.php.html +++ b/docs/files/core.table_foreign_key.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core.table_index.php.html b/docs/files/core.table_index.php.html index f698082..72153b7 100644 --- a/docs/files/core.table_index.php.html +++ b/docs/files/core.table_index.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/core/abstract/abstract_driver.php.txt b/docs/files/core/abstract/abstract_driver.php.txt index aee0e9c..dcd0a91 100644 --- a/docs/files/core/abstract/abstract_driver.php.txt +++ b/docs/files/core/abstract/abstract_driver.php.txt @@ -75,7 +75,7 @@ abstract class Abstract_Driver extends \PDO implements Driver_Interface { * Whether the driver supports 'TRUNCATE' * @var bool */ - public $has_truncate = TRUE; + protected $has_truncate = TRUE; /** * PDO constructor wrapper @@ -145,7 +145,7 @@ abstract class Abstract_Driver extends \PDO implements Driver_Interface { /** * Get the SQL class for the current driver * - * @return SQL_Interface + * @return SQL\SQL_Interface */ public function get_sql() { @@ -157,7 +157,7 @@ abstract class Abstract_Driver extends \PDO implements Driver_Interface { /** * Get the Util class for the current driver * - * @return Abstract_Util + * @return Util\Abstract_Util */ public function get_util() { diff --git a/docs/files/core/abstract/abstract_query_builder.php.txt b/docs/files/core/abstract/abstract_query_builder.php.txt new file mode 100644 index 0000000..df92642 --- /dev/null +++ b/docs/files/core/abstract/abstract_query_builder.php.txt @@ -0,0 +1,607 @@ + 'where', + * 'conjunction' => ' AND ', + * 'string' => 'k=?' + * ) + * + * @var array + */ + protected $query_map = array(); + + /** + * Map for having clause + * @var array + */ + protected $having_map; + + /** + * Convenience property for connection management + * @var string + */ + public $conn_name = ""; + + /** + * List of queries executed + * @var array + */ + public $queries; + + /** + * Whether to do only an explain on the query + * @var bool + */ + protected $explain; + + // -------------------------------------------------------------------------- + // Methods + // -------------------------------------------------------------------------- + + /** + * Calls a function further down the inheritence chain + * + * @param string $name + * @param array $params + * @return mixed + * @throws \BadMethodCallException + */ + public function __call($name, $params) + { + // Allow camel-case method calls + $snake_name = \from_camel_case($name); + + foreach(array($this, $this->db) as $object) + { + foreach(array($name, $snake_name) as $method_name) + { + if (method_exists($object, $method_name)) + { + return call_user_func_array(array($object, $method_name), $params); + } + } + + } + + throw new \BadMethodCallException("Method does not exist"); + } + + // -------------------------------------------------------------------------- + + /** + * Method to simplify select_ methods + * + * @param string $field + * @param string|bool $as + * @return string + */ + protected function _select($field, $as = FALSE) + { + // Escape the identifiers + $field = $this->db->quote_ident($field); + + $as = ($as !== FALSE) + ? $this->db->quote_ident($as) + : $field; + + return "({$field}) AS {$as} "; + } + + // -------------------------------------------------------------------------- + + /** + * Helper function for returning sql strings + * + * @param string $type + * @param string $table + * @param bool $reset + * @return string + */ + protected function _get_compile($type, $table, $reset) + { + $sql = $this->_compile($type, $table); + + // Reset the query builder for the next query + if ($reset) + { + $this->reset_query(); + } + + return $sql; + } + + // -------------------------------------------------------------------------- + + /** + * Simplify 'like' methods + * + * @param string $field + * @param mixed $val + * @param string $pos + * @param string $like + * @param string $conj + * @return Query_Builder + */ + protected function _like($field, $val, $pos, $like='LIKE', $conj='AND') + { + $field = $this->db->quote_ident($field); + + // Add the like string into the order map + $l = $field. " {$like} ?"; + + if ($pos == 'before') + { + $val = "%{$val}"; + } + elseif ($pos == 'after') + { + $val = "{$val}%"; + } + else + { + $val = "%{$val}%"; + } + + $conj = (empty($this->query_map)) ? ' WHERE ' : " {$conj} "; + $this->_append_map($conj, $l, 'like'); + + // Add to the values array + $this->where_values[] = $val; + + return $this; + } + + // -------------------------------------------------------------------------- + + /** + * Simplify building having clauses + * + * @param mixed $key + * @param mixed $val + * @param string $conj + * @return Query_Builder + */ + protected function _having($key, $val=array(), $conj='AND') + { + $where = $this->_where($key, $val); + + // Create key/value placeholders + foreach($where as $f => $val) + { + // Split each key by spaces, in case there + // is an operator such as >, <, !=, etc. + $f_array = explode(' ', trim($f)); + + $item = $this->db->quote_ident($f_array[0]); + + // Simple key value, or an operator + $item .= (count($f_array) === 1) ? '=?' : " {$f_array[1]} ?"; + + // Put in the having map + $this->having_map[] = array( + 'conjunction' => ( ! empty($this->having_map)) ? " {$conj} " : ' HAVING ', + 'string' => $item + ); + } + + return $this; + } + + // -------------------------------------------------------------------------- + + /** + * Do all the repeditive stuff for where/having type methods + * + * @param mixed $key + * @param mixed $val + * @return array + */ + protected function _where($key, $val=array()) + { + $where = array(); + + // Key and value passed? Add them to the where array + if (is_scalar($key) && is_scalar($val)) + { + $where[$key] = $val; + $this->where_values[] = $val; + } + // Array or object, loop through and add to the where array + elseif ( ! is_scalar($key)) + { + foreach($key as $k => $v) + { + $where[$k] = $v; + $this->where_values[] = $v; + } + } + + return $where; + } + + // -------------------------------------------------------------------------- + + /** + * Simplify generating where string + * + * @param mixed $key + * @param mixed $val + * @param string $conj + * @return Query_Builder + */ + protected function _where_string($key, $val=array(), $conj='AND') + { + $where = $this->_where($key, $val); + + // Create key/value placeholders + foreach($where as $f => $val) + { + // Split each key by spaces, in case there + // is an operator such as >, <, !=, etc. + $f_array = explode(' ', trim($f)); + + $item = $this->db->quote_ident($f_array[0]); + + // Simple key value, or an operator + $item .= (count($f_array) === 1) ? '=?' : " {$f_array[1]} ?"; + + // Get the type of the first item in the query map + $first_item = end($this->query_map); + + // Determine the correct conjunction + if (empty($this->query_map)) + { + $conj = "\nWHERE "; + } + elseif ($first_item['type'] === 'group_start') + { + $conj = ''; + } + else + { + $conj = " {$conj} "; + } + + $this->_append_map($conj, $item, 'where'); + } + + return $this; + } + + // -------------------------------------------------------------------------- + + /** + * Simplify where_in methods + * + * @param mixed $key + * @param mixed $val + * @param string $in - The (not) in fragment + * @param string $conj - The where in conjunction + * @return Query_Builder + */ + protected function _where_in($key, $val=array(), $in='IN', $conj='AND') + { + $key = $this->db->quote_ident($key); + $params = array_fill(0, count($val), '?'); + + foreach($val as $v) + { + $this->where_values[] = $v; + } + + $conjunction = ( ! empty($this->query_map)) ? " {$conj} " : ' WHERE '; + $str = $key . " {$in} (".implode(',', $params).') '; + + $this->_append_map($conjunction, $str, 'where_in'); + + return $this; + } + + // -------------------------------------------------------------------------- + + /** + * Executes the compiled query + * + * @param string $type + * @param string $table + * @param string $sql + * @param array|null $vals + * @return \PDOStatement + */ + protected function _run($type, $table, $sql=NULL, $vals=NULL) + { + if (is_null($sql)) + { + $sql = $this->_compile($type, $table); + } + + if (is_null($vals)) + { + $vals = array_merge($this->values, (array) $this->where_values); + } + + $start_time = microtime(TRUE); + + $res = (empty($vals)) + ? $this->db->query($sql) + : $this->db->prepare_execute($sql, $vals); + + $end_time = microtime(TRUE); + $total_time = number_format($end_time - $start_time, 5); + + // Add this query to the list of executed queries + $this->_append_query($vals, $sql, $total_time); + + // Reset class state for next query + $this->reset_query(); + + return $res; + } + + // -------------------------------------------------------------------------- + + /** + * Add an additional set of mapping pairs to a internal map + * + * @param string $conjunction + * @param string $string + * @param string $type + * @return void + */ + protected function _append_map($conjunction = '', $string = '', $type = '') + { + array_push($this->query_map, array( + 'type' => $type, + 'conjunction' => $conjunction, + 'string' => $string + )); + } + + // -------------------------------------------------------------------------- + + /** + * Convert the prepared statement into readable sql + * + * @param array $vals + * @param string $sql + * @param string $total_time + * @return void + */ + protected function _append_query($vals, $sql, $total_time) + { + $evals = (is_array($vals)) ? $vals : array(); + $esql = str_replace('?', "%s", $sql); + + // Quote string values + foreach($evals as &$v) + { + $v = ( ! is_numeric($v)) ? htmlentities($this->db->quote($v), ENT_NOQUOTES, 'utf-8', FALSE) : $v; + } + + // Add the query onto the array of values to pass + // as arguments to sprintf + array_unshift($evals, $esql); + + // Add the interpreted query to the list of executed queries + $this->queries[] = array( + 'time' => $total_time, + 'sql' => call_user_func_array('sprintf', $evals), + ); + + $this->queries['total_time'] += $total_time; + + // Set the last query to get rowcounts properly + $this->db->last_query = $sql; + } + + // -------------------------------------------------------------------------- + + /** + * Sub-method for generating sql strings + * + * @param string $type + * @param string $table + * @return string + */ + protected function _compile_type($type='', $table='') + { + if ($type === 'insert') + { + $param_count = count($this->set_array_keys); + $params = array_fill(0, $param_count, '?'); + $sql = "INSERT INTO {$table} (" + . implode(',', $this->set_array_keys) + . ")\nVALUES (".implode(',', $params).')'; + } + elseif ($type === 'update') + { + $sql = "UPDATE {$table}\nSET {$this->set_string}"; + } + elseif ($type === 'delete') + { + $sql = "DELETE FROM {$table}"; + } + else // GET queries + { + $sql = "SELECT * \nFROM {$this->from_string}"; + + // Set the select string + if ( ! empty($this->select_string)) + { + // Replace the star with the selected fields + $sql = str_replace('*', $this->select_string, $sql); + } + } + + return $sql; + } + + // -------------------------------------------------------------------------- + + /** + * String together the sql statements for sending to the db + * + * @param string $type + * @param string $table + * @return $string + */ + protected function _compile($type='', $table='') + { + // Get the base clause for the query + $sql = $this->_compile_type($type, $this->db->quote_table($table)); + + $clauses = array( + 'query_map', + 'group_string', + 'order_string', + 'having_map', + ); + + // Set each type of subclause + foreach($clauses as $clause) + { + $param = $this->$clause; + if (is_array($param)) + { + foreach($param as $q) + { + $sql .= $q['conjunction'] . $q['string']; + } + } + else + { + $sql .= $param; + } + } + + // Set the limit via the class variables + if (is_numeric($this->limit)) + { + $sql = $this->sql->limit($sql, $this->limit, $this->offset); + } + + // See if the query plan, rather than the + // query data should be returned + if ($this->explain === TRUE) + { + $sql = $this->sql->explain($sql); + } + + return $sql; + } +} + +// End of abstract_query_builder.php diff --git a/docs/files/core/query_builder.php.txt b/docs/files/core/query_builder.php.txt index 691256a..077bb08 100644 --- a/docs/files/core/query_builder.php.txt +++ b/docs/files/core/query_builder.php.txt @@ -14,9 +14,10 @@ // -------------------------------------------------------------------------- namespace Query; - use \Query\Driver\Driver_Interface; +// -------------------------------------------------------------------------- + /** * Convenience class for creating sql queries - also the class that * instantiates the specific db driver @@ -24,130 +25,7 @@ use \Query\Driver\Driver_Interface; * @package Query * @subpackage Query_Builder */ -class Query_Builder implements Query_Builder_Interface { - - // -------------------------------------------------------------------------- - // ! SQL Clause Strings - // -------------------------------------------------------------------------- - - /** - * Compiled 'select' clause - * @var string - */ - protected $select_string = ''; - - /** - * Compiled 'from' clause - * @var string - */ - protected $from_string; - - /** - * Compiled arguments for insert / update - * @var string - */ - protected $set_string; - - /** - * Order by clause - * @var string - */ - protected $order_string; - - /** - * Group by clause - * @var string - */ - protected $group_string; - - // -------------------------------------------------------------------------- - // ! SQL Clause Arrays - // -------------------------------------------------------------------------- - - /** - * Keys for insert/update statement - * @var array - */ - protected $set_array_keys = array(); - - /** - * Key/val pairs for order by clause - * @var array - */ - protected $order_array = array(); - - /** - * Key/val pairs for group by clause - * @var array - */ - protected $group_array = array(); - - // -------------------------------------------------------------------------- - // ! Other Class vars - // -------------------------------------------------------------------------- - - /** - * Values to apply to prepared statements - * @var array - */ - protected $values = array(); - - /** - * Values to apply to where clauses in prepared statements - * @var array - */ - protected $where_values = array(); - - /** - * Value for limit string - * @var string - */ - protected $limit; - - /** - * Value for offset in limit string - * @var int - */ - protected $offset; - - /** - * Query component order mapping - * for complex select queries - * - * Format: - * array( - * 'type' => 'where', - * 'conjunction' => ' AND ', - * 'string' => 'k=?' - * ) - * - * @var array - */ - protected $query_map = array(); - - /** - * Map for having clause - * @var array - */ - protected $having_map; - - /** - * Convenience property for connection management - * @var string - */ - public $conn_name = ""; - - /** - * List of queries executed - * @var array - */ - public $queries; - - /** - * Whether to do only an explain on the query - * @var bool - */ - protected $explain; +class Query_Builder extends Abstract_Query_Builder { /** * The current database driver @@ -211,25 +89,6 @@ class Query_Builder implements Query_Builder_Interface { // ! Select Queries // -------------------------------------------------------------------------- - /** - * Method to simplify select_ methods - * - * @param string $field - * @param string|bool $as - * @return string - */ - protected function _select($field, $as = FALSE) - { - // Escape the identifiers - $field = $this->db->quote_ident($field); - - $as = ($as !== FALSE) - ? $this->db->quote_ident($as) - : $field; - - return "({$field}) AS {$as} "; - } - /** * Specifies rows to select in a query * @@ -392,47 +251,6 @@ class Query_Builder implements Query_Builder_Interface { // ! 'Like' methods // -------------------------------------------------------------------------- - /** - * Simplify 'like' methods - * - * @param string $field - * @param mixed $val - * @param string $pos - * @param string $like - * @param string $conj - * @return Query_Builder - */ - protected function _like($field, $val, $pos, $like='LIKE', $conj='AND') - { - $field = $this->db->quote_ident($field); - - // Add the like string into the order map - $l = $field. " {$like} ?"; - - if ($pos == 'before') - { - $val = "%{$val}"; - } - elseif ($pos == 'after') - { - $val = "{$val}%"; - } - else - { - $val = "%{$val}%"; - } - - $conj = (empty($this->query_map)) ? ' WHERE ' : " {$conj} "; - $this->_append_map($conj, $l, 'like'); - - // Add to the values array - $this->where_values[] = $val; - - return $this; - } - - // -------------------------------------------------------------------------- - /** * Creates a Like clause in the sql statement * @@ -495,42 +313,6 @@ class Query_Builder implements Query_Builder_Interface { // ! Having methods // -------------------------------------------------------------------------- - /** - * Simplify building having clauses - * - * @param mixed $key - * @param mixed $val - * @param string $conj - * @return Query_Builder - */ - protected function _having($key, $val=array(), $conj='AND') - { - $where = $this->_where($key, $val); - - // Create key/value placeholders - foreach($where as $f => $val) - { - // Split each key by spaces, in case there - // is an operator such as >, <, !=, etc. - $f_array = explode(' ', trim($f)); - - $item = $this->db->quote_ident($f_array[0]); - - // Simple key value, or an operator - $item .= (count($f_array) === 1) ? '=?' : " {$f_array[1]} ?"; - - // Put in the having map - $this->having_map[] = array( - 'conjunction' => ( ! empty($this->having_map)) ? " {$conj} " : ' HAVING ', - 'string' => $item - ); - } - - return $this; - } - - // -------------------------------------------------------------------------- - /** * Generates a 'Having' clause * @@ -561,116 +343,6 @@ class Query_Builder implements Query_Builder_Interface { // ! 'Where' methods // -------------------------------------------------------------------------- - /** - * Do all the repedative stuff for where/having type methods - * - * @param mixed $key - * @param mixed $val - * @return array - */ - protected function _where($key, $val=array()) - { - $where = array(); - - // Key and value passed? Add them to the where array - if (is_scalar($key) && is_scalar($val)) - { - $where[$key] = $val; - $this->where_values[] = $val; - } - // Array or object, loop through and add to the where array - elseif ( ! is_scalar($key)) - { - foreach($key as $k => $v) - { - $where[$k] = $v; - $this->where_values[] = $v; - } - } - - return $where; - } - - // -------------------------------------------------------------------------- - - /** - * Simplify generating where string - * - * @param mixed $key - * @param mixed $val - * @param string $conj - * @return Query_Builder - */ - protected function _where_string($key, $val=array(), $conj='AND') - { - $where = $this->_where($key, $val); - - // Create key/value placeholders - foreach($where as $f => $val) - { - // Split each key by spaces, in case there - // is an operator such as >, <, !=, etc. - $f_array = explode(' ', trim($f)); - - $item = $this->db->quote_ident($f_array[0]); - - // Simple key value, or an operator - $item .= (count($f_array) === 1) ? '=?' : " {$f_array[1]} ?"; - - // Get the type of the first item in the query map - $first_item = end($this->query_map); - - // Determine the correct conjunction - if (empty($this->query_map)) - { - $conj = "\nWHERE "; - } - elseif ($first_item['type'] === 'group_start') - { - $conj = ''; - } - else - { - $conj = " {$conj} "; - } - - $this->_append_map($conj, $item, 'where'); - } - - return $this; - } - - // -------------------------------------------------------------------------- - - /** - * Simplify where_in methods - * - * @param mixed $key - * @param mixed $val - * @param string $in - The (not) in fragment - * @param string $conj - The where in conjunction - * @return Query_Builder - */ - protected function _where_in($key, $val=array(), $in='IN', $conj='AND') - { - $key = $this->db->quote_ident($key); - $params = array_fill(0, count($val), '?'); - - foreach($val as $v) - { - $this->where_values[] = $v; - } - - $conjunction = ( ! empty($this->query_map)) ? " {$conj} " : ' WHERE '; - $str = $key . " {$in} (".implode(',', $params).') '; - - $this->_append_map($conjunction, $str, 'where_in'); - - return $this; - } - - // -------------------------------------------------------------------------- - /** * Specify condition(s) in the where clause of a query * Note: this function works with key / value, or a @@ -1137,28 +809,7 @@ class Query_Builder implements Query_Builder_Interface { // ! SQL Returning Methods // -------------------------------------------------------------------------- - /** - * Helper function for returning sql strings - * - * @param string $type - * @param string $table - * @param bool $reset - * @return string - */ - protected function _get_compile($type, $table, $reset) - { - $sql = $this->_compile($type, $table); - // Reset the query builder for the next query - if ($reset) - { - $this->reset_query(); - } - - return $sql; - } - - // -------------------------------------------------------------------------- /** * Returns the generated 'select' sql query @@ -1261,228 +912,5 @@ class Query_Builder implements Query_Builder_Interface { $this->$var = array(); } } - - // -------------------------------------------------------------------------- - - /** - * Executes the compiled query - * - * @param string $type - * @param string $table - * @param string $sql - * @param array|null $vals - * @return \PDOStatement - */ - protected function _run($type, $table, $sql=NULL, $vals=NULL) - { - if (is_null($sql)) - { - $sql = $this->_compile($type, $table); - } - - if (is_null($vals)) - { - $vals = array_merge($this->values, (array) $this->where_values); - } - - $start_time = microtime(TRUE); - - $res = (empty($vals)) - ? $this->db->query($sql) - : $this->db->prepare_execute($sql, $vals); - - $end_time = microtime(TRUE); - $total_time = number_format($end_time - $start_time, 5); - - // Add this query to the list of executed queries - $this->_append_query($vals, $sql, $total_time); - - // Reset class state for next query - $this->reset_query(); - - return $res; - } - - // -------------------------------------------------------------------------- - - /** - * Calls a function further down the inheritence chain - * - * @param string $name - * @param array $params - * @return mixed - * @throws \BadMethodCallException - */ - public function __call($name, $params) - { - // Allow camel-case method calls - $snake_name = \from_camel_case($name); - - foreach(array($this, $this->db) as $object) - { - foreach(array($name, $snake_name) as $method_name) - { - if (method_exists($object, $method_name)) - { - return call_user_func_array(array($object, $method_name), $params); - } - } - - } - - throw new \BadMethodCallException("Method does not exist"); - } - - // -------------------------------------------------------------------------- - - /** - * Convert the prepared statement into readable sql - * - * @param array $vals - * @param string $sql - * @param string $total_time - * @return void - */ - protected function _append_query($vals, $sql, $total_time) - { - $evals = (is_array($vals)) ? $vals : array(); - $esql = str_replace('?', "%s", $sql); - - // Quote string values - foreach($evals as &$v) - { - $v = ( ! is_numeric($v)) ? htmlentities($this->db->quote($v), ENT_NOQUOTES, 'utf-8', FALSE) : $v; - } - - // Add the query onto the array of values to pass - // as arguments to sprintf - array_unshift($evals, $esql); - - // Add the interpreted query to the list of executed queries - $this->queries[] = array( - 'time' => $total_time, - 'sql' => call_user_func_array('sprintf', $evals), - ); - - $this->queries['total_time'] += $total_time; - - // Set the last query to get rowcounts properly - $this->db->last_query = $sql; - } - - // -------------------------------------------------------------------------- - - /** - * Add an additional set of mapping pairs to a internal map - * - * @param string $conjunction - * @param string $string - * @param string $type - * @return void - */ - protected function _append_map($conjunction = '', $string = '', $type = '') - { - array_push($this->query_map, array( - 'type' => $type, - 'conjunction' => $conjunction, - 'string' => $string - )); - } - - // -------------------------------------------------------------------------- - - /** - * Sub-method for generating sql strings - * - * @param string $type - * @param string $table - * @return string - */ - protected function _compile_type($type='', $table='') - { - if ($type === 'insert') - { - $param_count = count($this->set_array_keys); - $params = array_fill(0, $param_count, '?'); - $sql = "INSERT INTO {$table} (" - . implode(',', $this->set_array_keys) - . ")\nVALUES (".implode(',', $params).')'; - } - elseif ($type === 'update') - { - $sql = "UPDATE {$table}\nSET {$this->set_string}"; - } - elseif ($type === 'delete') - { - $sql = "DELETE FROM {$table}"; - } - else // GET queries - { - $sql = "SELECT * \nFROM {$this->from_string}"; - - // Set the select string - if ( ! empty($this->select_string)) - { - // Replace the star with the selected fields - $sql = str_replace('*', $this->select_string, $sql); - } - } - - return $sql; - } - - // -------------------------------------------------------------------------- - - /** - * String together the sql statements for sending to the db - * - * @param string $type - * @param string $table - * @return $string - */ - protected function _compile($type='', $table='') - { - // Get the base clause for the query - $sql = $this->_compile_type($type, $this->db->quote_table($table)); - - $clauses = array( - 'query_map', - 'group_string', - 'order_string', - 'having_map', - ); - - // Set each type of subclause - foreach($clauses as $clause) - { - $param = $this->$clause; - if (is_array($param)) - { - foreach($param as $q) - { - $sql .= $q['conjunction'] . $q['string']; - } - } - else - { - $sql .= $param; - } - } - - // Set the limit via the class variables - if (is_numeric($this->limit)) - { - $sql = $this->sql->limit($sql, $this->limit, $this->offset); - } - - // See if the query plan, rather than the - // query data should be returned - if ($this->explain === TRUE) - { - $sql = $this->sql->explain($sql); - } - - return $sql; - } } // End of query_builder.php diff --git a/docs/files/drivers.firebird.firebird_driver.php.html b/docs/files/drivers.firebird.firebird_driver.php.html index 3fabd7d..480f928 100644 --- a/docs/files/drivers.firebird.firebird_driver.php.html +++ b/docs/files/drivers.firebird.firebird_driver.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.firebird.firebird_result.php.html b/docs/files/drivers.firebird.firebird_result.php.html index 1357d09..b519c83 100644 --- a/docs/files/drivers.firebird.firebird_result.php.html +++ b/docs/files/drivers.firebird.firebird_result.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -384,7 +385,7 @@ data-fetching methods

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.firebird.firebird_sql.php.html b/docs/files/drivers.firebird.firebird_sql.php.html index 96b065a..0eebc94 100644 --- a/docs/files/drivers.firebird.firebird_sql.php.html +++ b/docs/files/drivers.firebird.firebird_sql.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.firebird.firebird_util.php.html b/docs/files/drivers.firebird.firebird_util.php.html index 845288b..3fa616d 100644 --- a/docs/files/drivers.firebird.firebird_util.php.html +++ b/docs/files/drivers.firebird.firebird_util.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.mysql.mysql_driver.php.html b/docs/files/drivers.mysql.mysql_driver.php.html index e54d0d6..4437c89 100644 --- a/docs/files/drivers.mysql.mysql_driver.php.html +++ b/docs/files/drivers.mysql.mysql_driver.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.mysql.mysql_sql.php.html b/docs/files/drivers.mysql.mysql_sql.php.html index 642b0b9..1886f9d 100644 --- a/docs/files/drivers.mysql.mysql_sql.php.html +++ b/docs/files/drivers.mysql.mysql_sql.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.mysql.mysql_util.php.html b/docs/files/drivers.mysql.mysql_util.php.html index 03b063a..8d9e4bb 100644 --- a/docs/files/drivers.mysql.mysql_util.php.html +++ b/docs/files/drivers.mysql.mysql_util.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.pgsql.pgsql_driver.php.html b/docs/files/drivers.pgsql.pgsql_driver.php.html index cd1973e..8ed0c2b 100644 --- a/docs/files/drivers.pgsql.pgsql_driver.php.html +++ b/docs/files/drivers.pgsql.pgsql_driver.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.pgsql.pgsql_sql.php.html b/docs/files/drivers.pgsql.pgsql_sql.php.html index 78da08c..aed0b85 100644 --- a/docs/files/drivers.pgsql.pgsql_sql.php.html +++ b/docs/files/drivers.pgsql.pgsql_sql.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.pgsql.pgsql_util.php.html b/docs/files/drivers.pgsql.pgsql_util.php.html index 92279a1..ce08ba8 100644 --- a/docs/files/drivers.pgsql.pgsql_util.php.html +++ b/docs/files/drivers.pgsql.pgsql_util.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.sqlite.sqlite_driver.php.html b/docs/files/drivers.sqlite.sqlite_driver.php.html index 154572a..732b5ed 100644 --- a/docs/files/drivers.sqlite.sqlite_driver.php.html +++ b/docs/files/drivers.sqlite.sqlite_driver.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.sqlite.sqlite_sql.php.html b/docs/files/drivers.sqlite.sqlite_sql.php.html index b42500c..00bce8f 100644 --- a/docs/files/drivers.sqlite.sqlite_sql.php.html +++ b/docs/files/drivers.sqlite.sqlite_sql.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers.sqlite.sqlite_util.php.html b/docs/files/drivers.sqlite.sqlite_util.php.html index 01fa65f..2d58e8b 100644 --- a/docs/files/drivers.sqlite.sqlite_util.php.html +++ b/docs/files/drivers.sqlite.sqlite_util.php.html @@ -114,12 +114,12 @@ @@ -139,28 +139,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -179,19 +179,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -211,10 +211,10 @@
- + Util
-
+ @@ -383,7 +384,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/files/drivers/firebird/firebird_driver.php.txt b/docs/files/drivers/firebird/firebird_driver.php.txt index 363645c..2890580 100644 --- a/docs/files/drivers/firebird/firebird_driver.php.txt +++ b/docs/files/drivers/firebird/firebird_driver.php.txt @@ -15,10 +15,6 @@ namespace Query\Driver; -use Query\Table\Table_Builder; - -// -------------------------------------------------------------------------- - /** * Firebird Database class * diff --git a/docs/graphs/class.html b/docs/graphs/class.html index dde8c63..0bf0a82 100644 --- a/docs/graphs/class.html +++ b/docs/graphs/class.html @@ -91,12 +91,12 @@ @@ -156,7 +156,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/graphs/classes.svg b/docs/graphs/classes.svg index 3767552..d5b3d1f 100644 --- a/docs/graphs/classes.svg +++ b/docs/graphs/classes.svg @@ -4,340 +4,351 @@ - - + + G - + cluster_Global - - - - - - - + + + + + + + -\ +\ cluster_\Query - - - - - - - + + + + + + + -Query +Query cluster_\Query\Table - - - - - - - - -Table + + + + + + + + +Table cluster_\Query\Driver - - - - - - - - -Driver + + + + + + + + +Driver cluster_\Query\Driver\SQL - - - - - - - - -SQL + + + + + + + + +SQL cluster_\Query\Driver\Util - - - - - - - - -Util + + + + + + + + +Util \\Query\\Table\\Abstract_Table - -«abstract» -Abstract_Table + +«abstract» +Abstract_Table \\Query\\Table\\Table_Builder - -Table_Builder + +Table_Builder \\Query\\Table\\Table_Foreign_Key - -Table_Foreign_Key + +Table_Foreign_Key \\Query\\Table\\Table_Foreign_Key->\\Query\\Table\\Abstract_Table - - + + \\Query\\Table\\Table_Column - -Table_Column + +Table_Column \\Query\\Table\\Table_Column->\\Query\\Table\\Abstract_Table - - + + \\Query\\Table\\Table_Index - -Table_Index + +Table_Index -\\Query\\Table\\Table_Index->\\Query\\Table\\Abstract_Table - - +\\Query\\Table\\Table_Index->\\Query\\Table\\Abstract_Table + + \\Query\\Driver\\SQL\\Abstract_SQL - -«abstract» -Abstract_SQL + +«abstract» +Abstract_SQL \\Query\\Driver\\SQL\\SQL_Interface - -SQL_Interface + +SQL_Interface \\Query\\Driver\\SQL\\Abstract_SQL->\\Query\\Driver\\SQL\\SQL_Interface - - + + \\Query\\Driver\\SQL\\PgSQL_SQL - -PgSQL_SQL + +PgSQL_SQL \\Query\\Driver\\SQL\\PgSQL_SQL->\\Query\\Driver\\SQL\\Abstract_SQL - - + + \\Query\\Driver\\SQL\\MySQL_SQL - -MySQL_SQL + +MySQL_SQL \\Query\\Driver\\SQL\\MySQL_SQL->\\Query\\Driver\\SQL\\Abstract_SQL - - + + \\Query\\Driver\\SQL\\Firebird_SQL - -Firebird_SQL + +Firebird_SQL \\Query\\Driver\\SQL\\Firebird_SQL->\\Query\\Driver\\SQL\\Abstract_SQL - - + + \\Query\\Driver\\SQL\\SQLite_SQL - -SQLite_SQL + +SQLite_SQL \\Query\\Driver\\SQL\\SQLite_SQL->\\Query\\Driver\\SQL\\Abstract_SQL - - + + \\Query\\Driver\\Util\\Firebird_Util - -Firebird_Util + +Firebird_Util \\Query\\Driver\\Util\\Abstract_Util - -«abstract» -Abstract_Util + +«abstract» +Abstract_Util \\Query\\Driver\\Util\\Firebird_Util->\\Query\\Driver\\Util\\Abstract_Util - - + + \\Query\\Driver\\Util\\MySQL_Util - -MySQL_Util + +MySQL_Util \\Query\\Driver\\Util\\MySQL_Util->\\Query\\Driver\\Util\\Abstract_Util - - + + \\Query\\Driver\\Util\\SQLite_Util - -SQLite_Util + +SQLite_Util \\Query\\Driver\\Util\\SQLite_Util->\\Query\\Driver\\Util\\Abstract_Util - - + + \\Query\\Driver\\Util\\PgSQL_Util - -PgSQL_Util + +PgSQL_Util \\Query\\Driver\\Util\\PgSQL_Util->\\Query\\Driver\\Util\\Abstract_Util - - + + \\Query\\Driver\\Firebird_Result - -Firebird_Result + +Firebird_Result -\\PDOStatement - -\PDOStatement +\\PDOStatement + +\PDOStatement \\Query\\Driver\\Firebird_Result->\\PDOStatement - - + + \\Query\\Driver\\Firebird - -Firebird + +Firebird \\Query\\Driver\\Abstract_Driver - -«abstract» -Abstract_Driver + +«abstract» +Abstract_Driver \\Query\\Driver\\Firebird->\\Query\\Driver\\Abstract_Driver - - + + \\Query\\Driver\\Driver_Interface - -Driver_Interface + +Driver_Interface \\Query\\Driver\\Abstract_Driver->\\Query\\Driver\\Driver_Interface - - + + -\\PDO - -\PDO +\\PDO + +\PDO \\Query\\Driver\\Abstract_Driver->\\PDO - - + + \\Query\\Driver\\SQLite - -SQLite + +SQLite \\Query\\Driver\\SQLite->\\Query\\Driver\\Abstract_Driver - - + + \\Query\\Driver\\PgSQL - -PgSQL + +PgSQL \\Query\\Driver\\PgSQL->\\Query\\Driver\\Abstract_Driver - - + + \\Query\\Driver\\MySQL - -MySQL + +MySQL -\\Query\\Driver\\MySQL->\\Query\\Driver\\Abstract_Driver - - +\\Query\\Driver\\MySQL->\\Query\\Driver\\Abstract_Driver + + \\Query\\Query_Parser - -Query_Parser + +Query_Parser \\Query\\Query_Builder - -Query_Builder + +Query_Builder - -\\Query\\Query_Builder_Interface - -Query_Builder_Interface + +\\Query\\Abstract_Query_Builder + +«abstract» +Abstract_Query_Builder - -\\Query\\Query_Builder->\\Query\\Query_Builder_Interface - - + +\\Query\\Query_Builder->\\Query\\Abstract_Query_Builder + + \\Query\\BadDBDriverException - -BadDBDriverException + +BadDBDriverException -\\InvalidArgumentException - -\InvalidArgumentException +\\InvalidArgumentException + +\InvalidArgumentException \\Query\\BadDBDriverException->\\InvalidArgumentException - - + + \\Query\\Connection_Manager - -Connection_Manager + +Connection_Manager + + +\\Query\\Query_Builder_Interface + +Query_Builder_Interface + + +\\Query\\Abstract_Query_Builder->\\Query\\Query_Builder_Interface + + diff --git a/docs/namespaces/Query.Driver.SQL.html b/docs/namespaces/Query.Driver.SQL.html index 4ab5466..dc7932a 100644 --- a/docs/namespaces/Query.Driver.SQL.html +++ b/docs/namespaces/Query.Driver.SQL.html @@ -66,12 +66,12 @@ @@ -91,28 +91,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -131,19 +131,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -163,10 +163,10 @@
- + Util
-
+ @@ -322,7 +323,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/namespaces/Query.Driver.Util.html b/docs/namespaces/Query.Driver.Util.html index d87e24e..877ca92 100644 --- a/docs/namespaces/Query.Driver.Util.html +++ b/docs/namespaces/Query.Driver.Util.html @@ -66,12 +66,12 @@ @@ -91,28 +91,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -131,19 +131,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -163,10 +163,10 @@
- + Util
-
+ @@ -315,7 +316,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/namespaces/Query.Driver.html b/docs/namespaces/Query.Driver.html index 111c180..27176f6 100644 --- a/docs/namespaces/Query.Driver.html +++ b/docs/namespaces/Query.Driver.html @@ -66,12 +66,12 @@ @@ -91,28 +91,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -131,19 +131,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -163,10 +163,10 @@
- + Util
-
+ @@ -334,7 +335,7 @@ data-fetching methods

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/namespaces/Query.Table.html b/docs/namespaces/Query.Table.html index f000ed5..4615ccc 100644 --- a/docs/namespaces/Query.Table.html +++ b/docs/namespaces/Query.Table.html @@ -66,12 +66,12 @@ @@ -91,28 +91,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -131,19 +131,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -163,10 +163,10 @@
- + Util
-
+ @@ -313,7 +314,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/namespaces/Query.html b/docs/namespaces/Query.html index a314eae..2b0fbc2 100644 --- a/docs/namespaces/Query.html +++ b/docs/namespaces/Query.html @@ -66,12 +66,12 @@ @@ -91,28 +91,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -131,19 +131,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -163,10 +163,10 @@
- + Util
-
+ @@ -267,6 +268,10 @@ instantiates the specific db driver Connection_Manager Connection manager class to manage connections for the Query method + + + Abstract_Query_Builder + Abstract Class for internal implementation methods of the Query Builder
@@ -325,7 +330,7 @@ Query method

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/namespaces/default.html b/docs/namespaces/default.html index a9a01c0..1b29518 100644 --- a/docs/namespaces/default.html +++ b/docs/namespaces/default.html @@ -66,12 +66,12 @@ @@ -91,28 +91,28 @@
- + \
-
+
- + Query
-
+
- + Table
-
+
@@ -131,19 +131,19 @@
- + Driver
-
+
- + SQL
-
+
@@ -163,10 +163,10 @@
- + Util
-
+ @@ -747,7 +748,7 @@ connection created.


Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/reports/deprecated.html b/docs/reports/deprecated.html index 1a9b9c1..2bcd4d2 100644 --- a/docs/reports/deprecated.html +++ b/docs/reports/deprecated.html @@ -67,12 +67,12 @@ @@ -181,7 +181,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/reports/errors.html b/docs/reports/errors.html index 5023a9e..5b6ad95 100644 --- a/docs/reports/errors.html +++ b/docs/reports/errors.html @@ -67,12 +67,12 @@ @@ -92,7 +92,7 @@ +
@@ -161,6 +161,8 @@
+
+
@@ -201,7 +203,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.
diff --git a/docs/reports/markers.html b/docs/reports/markers.html index 7863d42..8257687 100644 --- a/docs/reports/markers.html +++ b/docs/reports/markers.html @@ -67,12 +67,12 @@ @@ -92,7 +92,7 @@ +
@@ -126,7 +126,7 @@
-
+
@@ -167,7 +167,7 @@

Documentation is powered by phpDocumentor and authored - on April 24th, 2014 at 16:24. + on April 24th, 2014 at 17:07.