Skip to content

Commit

Permalink
#22 Renames old Statement classes to Query
Browse files Browse the repository at this point in the history
Renamed new	Query to Statement to match mySQLI Statement class
  • Loading branch information
sbuberl committed Mar 1, 2019
1 parent 76c2383 commit 17191c9
Show file tree
Hide file tree
Showing 46 changed files with 113 additions and 120 deletions.
89 changes: 41 additions & 48 deletions src/Environment.php

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

class AlterSequence extends Statement
class AlterSequence extends Query
{
private $fullName;
private $ifExists;
Expand Down
4 changes: 2 additions & 2 deletions src/Statements/AlterTable.php → src/Queries/AlterTable.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

class AlterTable extends Statement
class AlterTable extends Query
{
private $tableName;
private $actions;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;
use FSQL\Functions;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements\AlterTableActions;
namespace FSQL\Queries\AlterTableActions;

use FSQL\Environment;

Expand Down
4 changes: 2 additions & 2 deletions src/Statements/Begin.php → src/Queries/Begin.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

class Begin extends Statement
class Begin extends Query
{
public function __construct(Environment $environment)
{
Expand Down
4 changes: 2 additions & 2 deletions src/Statements/Commit.php → src/Queries/Commit.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

class Commit extends Statement
class Commit extends Query
{
public function __construct(Environment $environment)
{
Expand Down
4 changes: 2 additions & 2 deletions src/Statements/CreateBase.php → src/Queries/CreateBase.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

abstract class CreateBase extends Statement
abstract class CreateBase extends Query
{
protected $fullName;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Database\Schema;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

class CreateSchema extends CreateBase
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Database\Table;
use FSQL\Environment;

abstract class DataModifyStatement extends Statement
abstract class DataModifyQuery extends Query
{
protected $affected = 0;

Expand Down
4 changes: 2 additions & 2 deletions src/Statements/Delete.php → src/Queries/Delete.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

class Delete extends DataModifyStatement
class Delete extends DataModifyQuery
{
private $tableFullName;
private $where;
Expand Down
4 changes: 2 additions & 2 deletions src/Statements/DropBase.php → src/Queries/DropBase.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

abstract class DropBase extends Statement
abstract class DropBase extends Query
{
protected $fullName;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Database\Schema;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

Expand Down
2 changes: 1 addition & 1 deletion src/Statements/DropTable.php → src/Queries/DropTable.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

Expand Down
4 changes: 2 additions & 2 deletions src/Statements/Insert.php → src/Queries/Insert.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;
use FSQL\Database\Key;

class Insert extends DataModifyStatement
class Insert extends DataModifyQuery
{
const REPLACE = 2;
const IGNORE = 1;
Expand Down
4 changes: 2 additions & 2 deletions src/Statements/Lock.php → src/Queries/Lock.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

class Lock extends Statement
class Lock extends Query
{
private $locks;

Expand Down
4 changes: 2 additions & 2 deletions src/Statements/Merge.php → src/Queries/Merge.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;
use FSQL\Utilities;

class Merge extends DataModifyStatement
class Merge extends DataModifyQuery
{
private $targetTableName;
private $sourceTableName;
Expand Down
4 changes: 2 additions & 2 deletions src/Statements/Statement.php → src/Queries/Query.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

abstract class Statement
abstract class Query
{
protected $environment;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;
use FSQL\Statements\AlterTableActions\Action;
use FSQL\Queries\AlterTableActions\Action;

class RenameTable extends Statement implements Action
class RenameTable extends Query implements Action
{
private $oldName;
private $newName;
Expand Down
4 changes: 2 additions & 2 deletions src/Statements/Rollback.php → src/Queries/Rollback.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

class Rollback extends Statement
class Rollback extends Query
{
public function __construct(Environment $environment)
{
Expand Down
4 changes: 2 additions & 2 deletions src/Statements/Select.php → src/Queries/Select.php
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;


use FSQL\Environment;
use FSQL\OrderByClause;
use FSQL\ResultSet;
use FSQL\Utilities;

class Select extends Statement
class Select extends Query
{
private $selectedInfo;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<?php

namespace FSQL\Statements;
namespace FSQL\Queries;

use FSQL\Environment;

class SetDatabase extends Statement
class SetDatabase extends Query
{
private $dbName;

Expand Down
Loading

0 comments on commit 17191c9

Please sign in to comment.