Skip to content

Commit

Permalink
The namespace was changed to 'Fabik\Database'. (BC break!)
Browse files Browse the repository at this point in the history
  • Loading branch information
fabik committed Nov 28, 2012
1 parent 7000e9f commit 83aaf50
Show file tree
Hide file tree
Showing 12 changed files with 28 additions and 28 deletions.
2 changes: 1 addition & 1 deletion Database/ActiveRow.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Database;
namespace Fabik\Database;
use Nette\ObjectMixin;


Expand Down
4 changes: 2 additions & 2 deletions Database/GroupedSelection.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Database;
namespace Fabik\Database;



Expand Down Expand Up @@ -32,7 +32,7 @@ public function __construct(\Nette\Database\Table\Selection $refTable, $name, $c



/********** Database\Selection behaviour **********/
/********** Fabik\Database\Selection behaviour **********/



Expand Down
2 changes: 1 addition & 1 deletion Database/IModelManager.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Database;
namespace Fabik\Database;



Expand Down
2 changes: 1 addition & 1 deletion Database/IModelManagerAccessor.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Database;
namespace Fabik\Database;



Expand Down
2 changes: 1 addition & 1 deletion Database/IRowFactory.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Database;
namespace Fabik\Database;



Expand Down
2 changes: 1 addition & 1 deletion Database/ModelManager.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Database;
namespace Fabik\Database;
use Nette\Caching\IStorage,
Nette\Database\Connection,
Nette\Database\IReflection,
Expand Down
4 changes: 2 additions & 2 deletions Database/RowFactory.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Database;
namespace Fabik\Database;
use Nette\Object;


Expand All @@ -24,7 +24,7 @@ class RowFactory extends Object implements IRowFactory
* @param string[]
* @param string
*/
public function __construct($classes = array(), $defaultClass = 'Database\ActiveRow')
public function __construct($classes = array(), $defaultClass = 'Fabik\Database\ActiveRow')
{
$this->classes = $classes;
$this->defaultClass = $defaultClass;
Expand Down
2 changes: 1 addition & 1 deletion Database/Selection.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Database;
namespace Fabik\Database;



Expand Down
2 changes: 1 addition & 1 deletion Database/Table.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Database;
namespace Fabik\Database;
use Nette\Object;


Expand Down
2 changes: 1 addition & 1 deletion Database/exceptions.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace Database;
namespace Fabik\Database;



Expand Down
20 changes: 10 additions & 10 deletions Database/loader.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,16 @@

spl_autoload_register(function ($type) {
static $paths = array(
'database\activerow' => 'ActiveRow.php',
'database\duplicateentryexception' => 'exceptions.php',
'database\groupedselection' => 'GroupedSelection.php',
'database\imodelmanager' => 'IModelManager.php',
'database\imodelmanageraccessor' => 'IModelManagerAccessor.php',
'database\irowfactory' => 'IRowFactory.php',
'database\modelmanager' => 'ModelManager.php',
'database\rowfactory' => 'RowFactory.php',
'database\selection' => 'Selection.php',
'database\table' => 'Table.php',
'fabik\database\activerow' => 'ActiveRow.php',
'fabik\database\duplicateentryexception' => 'exceptions.php',
'fabik\database\groupedselection' => 'GroupedSelection.php',
'fabik\database\imodelmanager' => 'IModelManager.php',
'fabik\database\imodelmanageraccessor' => 'IModelManagerAccessor.php',
'fabik\database\irowfactory' => 'IRowFactory.php',
'fabik\database\modelmanager' => 'ModelManager.php',
'fabik\database\rowfactory' => 'RowFactory.php',
'fabik\database\selection' => 'Selection.php',
'fabik\database\table' => 'Table.php',
);

$type = ltrim(strtolower($type), '\\'); // PHP namespace bug #49143
Expand Down
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Database
========
fabik/database
==============

This is a database layer for Nette Framework based on `Nette\Database`.

Expand Down Expand Up @@ -46,8 +46,8 @@ Get the source code using [Composer](http://getcomposer.org/) (add `"fabik/datab

services:
# database
modelManager: Database\ModelManager
rowFactory: Database\RowFactory({
modelManager: Fabik\Database\ModelManager
rowFactory: Fabik\Database\RowFactory({
articles: Blog\Article
users: Blog\User
})
Expand All @@ -63,8 +63,8 @@ Get the source code using [Composer](http://getcomposer.org/) (add `"fabik/datab
<?php

namespace Blog;
use Database\ActiveRow,
Database\Table;
use Fabik\Database\ActiveRow,
Fabik\Database\Table;



Expand Down

0 comments on commit 83aaf50

Please sign in to comment.