Skip to content

Commit

Permalink
Add Feature and FeatureCollection
Browse files Browse the repository at this point in the history
  • Loading branch information
fschmtt committed Nov 17, 2023
1 parent 01c0dd9 commit 5ea0c58
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 0 deletions.
20 changes: 20 additions & 0 deletions src/Collection/FeatureCollection.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?php

declare(strict_types=1);

namespace Fschmtt\Keycloak\Collection;

use Fschmtt\Keycloak\Representation\Feature;

/**
* @extends Collection<Feature>
*
* @codeCoverageIgnore
*/
class FeatureCollection extends Collection
{
public static function getRepresentationClass(): string
{
return Feature::class;
}
}
26 changes: 26 additions & 0 deletions src/Representation/Feature.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<?php

declare(strict_types=1);

namespace Fschmtt\Keycloak\Representation;

/**
* @method string|null getName()
* @method string|null getLabel()
* @method string|null getType()
* @method string[]|null getDependencies()
* @method bool|null getEnabled()
*
* @codeCoverageIgnore
*/
class Feature extends Representation
{
public function __construct(
protected ?string $name = null,
protected ?string $label = null,
protected ?string $type = null,
protected ?array $dependencies = null,
protected ?bool $enabled = null,
) {
}
}

0 comments on commit 5ea0c58

Please sign in to comment.