[Server] Reorganize server handlers and transport structure for better organization (#86)

* refactor: reorganize server handlers and transport structure

* feat: move the test files to corresponding directories

* fix: linter issues

* fix: correct PHPDoc formatting and streamline handler imports

* refactor: update import statement for ServerBuilder to Builder
This commit is contained in:
Kyrian Obikwelu 2025-09-28 23:58:04 +01:00 • committed by GitHub
commit 41486bfaa4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -11,9 +11,9 @@
namespace Mcp;
use Mcp\JsonRpc\Handler;
use Mcp\Server\Builder;
use Mcp\Server\TransportInterface;
use Mcp\Server\Handler\JsonRpcHandler;
use Mcp\Server\Transport\TransportInterface;
use Psr\Log\LoggerInterface;
use Psr\Log\NullLogger;
use Symfony\Component\Uid\Uuid;
@ -25,7 +25,7 @@ use Symfony\Component\Uid\Uuid;
final class Server
{
public function __construct(
private readonly Handler $jsonRpcHandler,
private readonly JsonRpcHandler $jsonRpcHandler,
private readonly LoggerInterface $logger = new NullLogger(),
) {
}