Overview

Namespaces

  • Neevo
    • Cache
    • Drivers
    • Nette
  • PHP

Classes

  • BaseStatement
  • Connection
  • Literal
  • Loader
  • Manager
  • Parser
  • Result
  • ResultIterator
  • Row
  • Statement

Interfaces

  • ICache
  • IDriver
  • IObservable
  • IObserver

Exceptions

  • DriverException
  • ImplementationException
  • NeevoException
  • Overview
  • Namespace
  • Class
  • Tree

Class Manager

Core Neevo class.

Neevo\Manager implements Neevo\IObservable, Neevo\IObserver
Namespace: Neevo
Author: Smasty
Located at Neevo/Manager.php
Methods summary
public
# __construct( mixed $config, Neevo\ICache $cache = null )

Configure Neevo and establish a connection. Configuration can be different - see the API for your driver.

Configure Neevo and establish a connection. Configuration can be different - see the API for your driver.

Parameters

$config
mixed
Connection configuration.
$cache
Neevo\ICache
Cache to use.

Throws

Neevo\NeevoException
public Neevo\Result
# select( string|array $columns = null, string $table = null )

SELECT statement factory.

SELECT statement factory.

Parameters

$columns
string|array
Array or comma-separated list (optional)
$table
string

Returns

Neevo\Result
fluent interface
public Neevo\Statement
# insert( string $table, array $values )

INSERT statement factory.

INSERT statement factory.

Parameters

$table
string
$values
array

Returns

Neevo\Statement
fluent interface
public Neevo\Statement
# update( string $table, array $data )

UPDATE statement factory.

UPDATE statement factory.

Parameters

$table
string
$data
array

Returns

Neevo\Statement
fluent interface
public Neevo\Statement
# delete( string $table )

DELETE statement factory.

DELETE statement factory.

Parameters

$table
string

Returns

Neevo\Statement
fluent interface
public integer
# loadFile( string $filename )

Import a SQL dump from given file. Based on implementation in Nette\Database.

Import a SQL dump from given file. Based on implementation in Nette\Database.

Parameters

$filename
string

Returns

integer
Number of executed commands

Copyright

2004-2012 David Grudl, http://davidgrudl.com

License

BSD license
public Neevo
# begin( string $savepoint = null )

Begin a transaction if supported.

Begin a transaction if supported.

Parameters

$savepoint
string

Returns

Neevo
fluent interface
public Neevo
# commit( string $savepoint = null )

Commit statements in a transaction.

Commit statements in a transaction.

Parameters

$savepoint
string

Returns

Neevo
fluent interface
public Neevo
# rollback( string $savepoint = null )

Rollback changes in a transaction.

Rollback changes in a transaction.

Parameters

$savepoint
string

Returns

Neevo
fluent interface
public
# attachObserver( Neevo\IObserver $observer, integer $event )

Attach an observer for debugging.

Attach an observer for debugging.

Parameters

$observer
Neevo\IObserver
$event
integer
Event to attach the observer to.

Implementation of

Neevo\IObservable::attachObserver
public
# detachObserver( Neevo\IObserver $observer )

Detach given observer.

Detach given observer.

Parameters

$observer
Neevo\IObserver

Implementation of

Neevo\IObservable::detachObserver
public
# notifyObservers( integer $event )

Notify all observers attached to given event.

Notify all observers attached to given event.

Parameters

$event
integer

Implementation of

Neevo\IObservable::notifyObservers
public
# updateStatus( Neevo\IObservable $subject, integer $event )

Receive update from observable subject.

Receive update from observable subject.

Parameters

$subject
Neevo\IObservable
$event
integer
Event type

Implementation of

Neevo\IObserver::updateStatus
public Neevo\Connection
# getConnection( )

Current Connection instance.

Current Connection instance.

Returns

Neevo\Connection
public string
# getLast( )

Last executed query.

Last executed query.

Returns

string
public integer
# getQueries( )

Get number of executed queries.

Get number of executed queries.

Returns

integer
public static string
# highlightSql( string $sql )

Highlight given SQL code.

Highlight given SQL code.

Parameters

$sql
string

Returns

string
Constants summary
string VERSION '2.0.1'
#
string REVISION '@VCREV@ released on @VCDATE@'
#
string BOOL 'b'
#
string INT 'i'
#
string FLOAT 'f'
#
string TEXT 's'
#
string BINARY 'bin'
#
string DATETIME 'd'
#
string ARR 'a'
#
string LITERAL 'l'
#
string IDENTIFIER 'id'
#
string SUBQUERY 'sub'
#
string STMT_SELECT 'stmt_select'
#
string STMT_INSERT 'stmt_insert'
#
string STMT_UPDATE 'stmt_update'
#
string STMT_DELETE 'stmt_delete'
#
string JOIN_LEFT 'join_left'
#
string JOIN_INNER 'join_inner'
#
string ASC 'ASC'
#
string DESC 'DESC'
#
Constants inherited from Neevo\IObserver
ALL, BEGIN, COMMIT, CONNECT, DELETE, DISCONNECT, EXCEPTION, INSERT, QUERY, ROLLBACK, SELECT, TRANSACTION, UPDATE
Properties summary
public static string $defaultDriver 'mysqli'
#

Default Neevo driver

Default Neevo driver

Neevo Public API API documentation generated by ApiGen 2.6.1