Procházet zdrojové kódy

Remove useless interface Predis\BasicClientInterface.

Daniele Alessandri před 10 roky
rodič
revize
a67d35b799

+ 0 - 31
src/BasicClientInterface.php

@@ -1,31 +0,0 @@
-<?php
-
-/*
- * This file is part of the Predis package.
- *
- * (c) Daniele Alessandri <suppakilla@gmail.com>
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-
-namespace Predis;
-
-use Predis\Command\CommandInterface;
-
-/**
- * Defines the interface of a basic client class or abstraction that can send
- * commands to Redis.
- *
- * @author Daniele Alessandri <suppakilla@gmail.com>
- */
-interface BasicClientInterface
-{
-    /**
-     * Executes the specified Redis command.
-     *
-     * @param  CommandInterface $command Command instance.
-     * @return mixed
-     */
-    public function executeCommand(CommandInterface $command);
-}

+ 11 - 3
src/ClientInterface.php

@@ -17,12 +17,12 @@ use Predis\Connection\ConnectionInterface;
 use Predis\Profile\ProfileInterface;
 
 /**
- * Interface defining the most important methods needed to create an high-level
- * Redis client that can interact with other building blocks of Predis.
+ * Interface defining an high-level Redis client that can interact with other
+ * building blocks of Predis.
  *
  * @author Daniele Alessandri <suppakilla@gmail.com>
  */
-interface ClientInterface extends BasicClientInterface
+interface ClientInterface
 {
     /**
      * Returns the server profile used by the client.
@@ -64,6 +64,14 @@ interface ClientInterface extends BasicClientInterface
      */
     public function createCommand($method, $arguments = array());
 
+    /**
+     * Executes the specified Redis command.
+     *
+     * @param  CommandInterface $command Command instance.
+     * @return mixed
+     */
+    public function executeCommand(CommandInterface $command);
+
     /**
      * Creates a Redis command with the specified arguments and sends a request
      * to the server.

+ 1 - 2
src/Pipeline/Pipeline.php

@@ -14,7 +14,6 @@ namespace Predis\Pipeline;
 use Exception;
 use InvalidArgumentException;
 use SplQueue;
-use Predis\BasicClientInterface;
 use Predis\ClientException;
 use Predis\ClientInterface;
 use Predis\ExecutableContextInterface;
@@ -31,7 +30,7 @@ use Predis\Response\ServerException;
  *
  * @author Daniele Alessandri <suppakilla@gmail.com>
  */
-class Pipeline implements BasicClientInterface, ExecutableContextInterface
+class Pipeline implements ExecutableContextInterface
 {
     private $client;
     private $pipeline;

+ 1 - 2
src/Transaction/MultiExec.php

@@ -14,7 +14,6 @@ namespace Predis\Transaction;
 use Exception;
 use InvalidArgumentException;
 use SplQueue;
-use Predis\BasicClientInterface;
 use Predis\ClientException;
 use Predis\ClientInterface;
 use Predis\CommunicationException;
@@ -32,7 +31,7 @@ use Predis\Protocol\ProtocolException;
  *
  * @author Daniele Alessandri <suppakilla@gmail.com>
  */
-class MultiExec implements BasicClientInterface, ExecutableContextInterface
+class MultiExec implements ExecutableContextInterface
 {
     private $state;