Skip to content
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
18 changes: 0 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ composer require php-skir/runtime
## What it provides

- `DenseJson` for encoding and decoding Skir dense JSON values.
- `Cbor` helpers for optional CBOR bodies and SkirRPC envelopes.
- `Type`, `Field`, and `Variant` descriptors for generated DTO metadata.
- `EnumValue` for Skir enum constants and wrapper variants.
- `MethodDescriptor` for generated SkirRPC method metadata.
Expand Down Expand Up @@ -47,23 +46,6 @@ $data = DenseJson::fromJson($user, $json);

Struct values are encoded as field-number indexed arrays. Removed fields and sparse field numbers are preserved so generated DTOs can stay compatible with existing Skir schemas.

## CBOR

CBOR support is optional and requires `spomky-labs/cbor-php` in the consuming app:

```bash
composer require spomky-labs/cbor-php
```

The runtime helper keeps CBOR wrapping shared between server and client packages:

```php
use Skir\Runtime\Cbor;

$body = Cbor::encodeEnvelope($methodDescriptor, $request);
$payload = Cbor::decodeEnvelope($body);
```

## Current scope

This runtime does not register routes, discover procedures, or make HTTP calls. Those concerns belong in the `php-skir/server` and `php-skir/client` packages.
8 changes: 2 additions & 6 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@
},
"require-dev": {
"laravel/pint": "^1.29",
"phpunit/phpunit": "^12.5",
"spomky-labs/cbor-php": "^3.2"
"phpunit/phpunit": "^12.5"
},
"autoload": {
"psr-4": {
Expand All @@ -41,16 +40,13 @@
},
"extra": {
"branch-alias": {
"dev-main": "0.1.x-dev"
"dev-main": "0.2.x-dev"
}
},
"scripts": {
"format": "pint",
"test": "phpunit"
},
"suggest": {
"spomky-labs/cbor-php": "Required when using Skir\\Runtime\\Cbor helpers."
},
"config": {
"sort-packages": true
},
Expand Down
109 changes: 0 additions & 109 deletions src/Cbor.php

This file was deleted.

10 changes: 0 additions & 10 deletions src/Exceptions/SkirRuntimeException.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,8 @@ public static function invalidDenseJson(string $message, ?Throwable $previous =
return new self("Invalid dense JSON: {$message}", previous: $previous);
}

public static function invalidCbor(string $message, ?Throwable $previous = null): self
{
return new self("Invalid CBOR: {$message}", previous: $previous);
}

public static function invalidValue(string $message): self
{
return new self($message);
}

public static function missingCborDependency(): self
{
return new self('Skir CBOR support requires the [spomky-labs/cbor-php] Composer package.');
}
}
86 changes: 0 additions & 86 deletions tests/CborTest.php

This file was deleted.

Loading