Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restructure files #127

Merged
merged 4 commits into from
Oct 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion config/di-providers-web.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

use Yiisoft\Yii\Debug\Api\Provider\DebugApiProvider;
use Yiisoft\Yii\Debug\Api\Debug\Provider\DebugApiProvider;

if (!(bool)($params['yiisoft/yii-debug-api']['enabled'] ?? false)) {
return [];
Expand Down
4 changes: 2 additions & 2 deletions config/di-web.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
use Cycle\Database\DatabaseProviderInterface;
use Psr\Container\ContainerInterface;
use Yiisoft\Db\Connection\ConnectionInterface;
use Yiisoft\Yii\Debug\Api\Debug\Repository\CollectorRepository;
use Yiisoft\Yii\Debug\Api\Debug\Repository\CollectorRepositoryInterface;
use Yiisoft\Yii\Debug\Api\Inspector\Database\ActiveRecord\ActiveRecordSchemaProvider;
use Yiisoft\Yii\Debug\Api\Inspector\Database\Cycle\CycleSchemaProvider;
use Yiisoft\Yii\Debug\Api\Inspector\Database\SchemaProviderInterface;
use Yiisoft\Yii\Debug\Api\Repository\CollectorRepository;
use Yiisoft\Yii\Debug\Api\Repository\CollectorRepositoryInterface;
use Yiisoft\Yii\Debug\Storage\StorageInterface;

/**
Expand Down
14 changes: 7 additions & 7 deletions config/routes.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
use Yiisoft\Router\Group;
use Yiisoft\Router\Route;
use Yiisoft\Validator\ValidatorInterface;
use Yiisoft\Yii\Debug\Api\Controller\CacheController;
use Yiisoft\Yii\Debug\Api\Controller\CommandController;
use Yiisoft\Yii\Debug\Api\Controller\ComposerController;
use Yiisoft\Yii\Debug\Api\Controller\DebugController;
use Yiisoft\Yii\Debug\Api\Controller\GitController;
use Yiisoft\Yii\Debug\Api\Controller\InspectController;
use Yiisoft\Yii\Debug\Api\Middleware\ResponseDataWrapper;
use Yiisoft\Yii\Debug\Api\Debug\Controller\DebugController;
use Yiisoft\Yii\Debug\Api\Debug\Middleware\ResponseDataWrapper;
use Yiisoft\Yii\Debug\Api\Inspector\Controller\CacheController;
use Yiisoft\Yii\Debug\Api\Inspector\Controller\CommandController;
use Yiisoft\Yii\Debug\Api\Inspector\Controller\ComposerController;
use Yiisoft\Yii\Debug\Api\Inspector\Controller\GitController;
use Yiisoft\Yii\Debug\Api\Inspector\Controller\InspectController;
use Yiisoft\Yii\Middleware\CorsAllowAll;
use Yiisoft\Yii\Middleware\IpFilter;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Controller;
namespace Yiisoft\Yii\Debug\Api\Debug\Controller;

use Psr\Container\ContainerInterface;
use Psr\Http\Message\ResponseFactoryInterface;
Expand All @@ -13,11 +13,11 @@
use Yiisoft\DataResponse\DataResponse;
use Yiisoft\DataResponse\DataResponseFactoryInterface;
use Yiisoft\Router\CurrentRoute;
use Yiisoft\Yii\Debug\Api\Exception\NotFoundException;
use Yiisoft\Yii\Debug\Api\Exception\PackageNotInstalledException;
use Yiisoft\Yii\Debug\Api\HtmlViewProviderInterface;
use Yiisoft\Yii\Debug\Api\ModuleFederationProviderInterface;
use Yiisoft\Yii\Debug\Api\Repository\CollectorRepositoryInterface;
use Yiisoft\Yii\Debug\Api\Debug\Exception\NotFoundException;
use Yiisoft\Yii\Debug\Api\Debug\Exception\PackageNotInstalledException;
use Yiisoft\Yii\Debug\Api\Debug\HtmlViewProviderInterface;
use Yiisoft\Yii\Debug\Api\Debug\ModuleFederationProviderInterface;
use Yiisoft\Yii\Debug\Api\Debug\Repository\CollectorRepositoryInterface;
use Yiisoft\Yii\Debug\Api\ServerSentEventsStream;
use Yiisoft\Yii\Debug\Storage\StorageInterface;
use Yiisoft\Yii\View\ViewRenderer;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Exception;
namespace Yiisoft\Yii\Debug\Api\Debug\Exception;

final class NotFoundException extends \Exception
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Exception;
namespace Yiisoft\Yii\Debug\Api\Debug\Exception;

use Exception;
use Throwable;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api;
namespace Yiisoft\Yii\Debug\Api\Debug;

use Yiisoft\Yii\Debug\Collector\CollectorInterface;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Middleware;
namespace Yiisoft\Yii\Debug\Api\Debug\Middleware;

use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Middleware;
namespace Yiisoft\Yii\Debug\Api\Debug\Middleware;

use OpenApi\Annotations as OA;
use Psr\Http\Message\ResponseInterface;
Expand All @@ -13,7 +13,7 @@
use Yiisoft\DataResponse\DataResponseFactoryInterface;
use Yiisoft\Http\Status;
use Yiisoft\Router\CurrentRoute;
use Yiisoft\Yii\Debug\Api\Exception\NotFoundException;
use Yiisoft\Yii\Debug\Api\Debug\Exception\NotFoundException;

/**
* @OA\Schema(schema="DebugResponse", description="Yii Debug Api response")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api;
namespace Yiisoft\Yii\Debug\Api\Debug;

if (!class_exists(\Yiisoft\Assets\AssetBundle::class)) {
class AssetBundle
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api;
namespace Yiisoft\Yii\Debug\Api\Debug;

use Yiisoft\Yii\Debug\Collector\CollectorInterface;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Provider;
namespace Yiisoft\Yii\Debug\Api\Debug\Provider;

use Psr\Container\ContainerInterface;
use Yiisoft\Di\ServiceProviderInterface;
use Yiisoft\Yii\Debug\Api\Middleware\DebugHeaders;
use Yiisoft\Router\RouteCollectorInterface;
use Yiisoft\Yii\Debug\Api\Debug\Middleware\DebugHeaders;

final class DebugApiProvider implements ServiceProviderInterface
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Repository;
namespace Yiisoft\Yii\Debug\Api\Debug\Repository;

use Yiisoft\Yii\Debug\Api\Exception\NotFoundException;
use Yiisoft\Yii\Debug\Api\Debug\Exception\NotFoundException;
use Yiisoft\Yii\Debug\Storage\StorageInterface;

final class CollectorRepository implements CollectorRepositoryInterface
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Repository;
namespace Yiisoft\Yii\Debug\Api\Debug\Repository;

interface CollectorRepositoryInterface
{
Expand All @@ -13,7 +13,7 @@ public function getDetail(string $id): array;
public function getDumpObject(string $id): array;

/**
* @return array<string, mixed>|null Returns a list with object class and it's value or null
* @return array{string, mixed}|null Returns a list with object class, and it's value or null
*/
public function getObject(string $id, string $objectId): array|null;
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Controller;
namespace Yiisoft\Yii\Debug\Api\Inspector\Controller;

use Psr\Container\ContainerInterface;
use Psr\Http\Message\ResponseInterface;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Controller;
namespace Yiisoft\Yii\Debug\Api\Inspector\Controller;

use InvalidArgumentException;
use Psr\Container\ContainerInterface;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Controller;
namespace Yiisoft\Yii\Debug\Api\Inspector\Controller;

use Exception;
use InvalidArgumentException;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Controller;
namespace Yiisoft\Yii\Debug\Api\Inspector\Controller;

use Gitonomy\Git\Commit;
use Gitonomy\Git\Reference\Branch;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Yiisoft\Yii\Debug\Api\Controller;
namespace Yiisoft\Yii\Debug\Api\Inspector\Controller;

use Alexkart\CurlBuilder\Command;
use FilesystemIterator;
Expand All @@ -28,9 +28,9 @@
use Yiisoft\Router\UrlMatcherInterface;
use Yiisoft\Translator\CategorySource;
use Yiisoft\VarDumper\VarDumper;
use Yiisoft\Yii\Debug\Api\Debug\Repository\CollectorRepositoryInterface;
use Yiisoft\Yii\Debug\Api\Inspector\ApplicationState;
use Yiisoft\Yii\Debug\Api\Inspector\Database\SchemaProviderInterface;
use Yiisoft\Yii\Debug\Api\Repository\CollectorRepositoryInterface;
use Yiisoft\Yii\Debug\Collector\Web\RequestCollector;

class InspectController
Expand Down