Skip to content
Snippets Groups Projects
Commit 11b8dc43 authored by micha.jakubowski's avatar micha.jakubowski Committed by Claudiu Cristea
Browse files

ISAICP-9407: Replace eu_oss_catalogue Annotation with Attribute

parent dff7288c
No related branches found
No related tags found
1 merge request!210Patch release 2.2.1
......@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace Drupal\eu_oss_catalogue\Annotation;
namespace Drupal\eu_oss_catalogue\Attribute;
use Attribute;
use Drupal\Component\Annotation\Plugin;
......@@ -51,4 +51,17 @@ class EuOssCatalogueHostingPlatform extends Plugin {
*/
public int $weight = 0;
/**
* @param string $id
* @param \Drupal\Core\Annotation\Translation $label
* @param string|null $baseUrl
* @param int $weight
*/
public function __construct(string $id, Translation $label, ?string $baseUrl, int $weight) {
$this->id = $id;
$this->label = $label;
$this->baseUrl = $baseUrl;
$this->weight = $weight;
}
}
......@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace Drupal\eu_oss_catalogue\Annotation;
namespace Drupal\eu_oss_catalogue\Attribute;
use Attribute;
use Drupal\Component\Annotation\Plugin;
......@@ -26,4 +26,13 @@ class EuOssCatalogueParser extends Plugin {
*/
public Translation $label;
/**
* @param string $id
* @param \Drupal\Core\Annotation\Translation $label
*/
public function __construct(string $id, Translation $label) {
$this->id = $id;
$this->label = $label;
}
}
......@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace Drupal\eu_oss_catalogue\Annotation;
namespace Drupal\eu_oss_catalogue\Attribute;
use Attribute;
use Drupal\Component\Annotation\Plugin;
......@@ -43,4 +43,19 @@ class EuOssCatalogueProvider extends Plugin {
*/
public ?string $configuredBy = NULL;
/**
* @param string $id
* @param \Drupal\Core\Annotation\Translation $label
* @param string $parser
* @param \Drupal\Core\Annotation\Translation|null $description
* @param string|null $configuredBy
*/
public function __construct(string $id, Translation $label, string $parser, ?Translation $description, ?string $configuredBy) {
$this->id = $id;
$this->label = $label;
$this->parser = $parser;
$this->description = $description;
$this->configuredBy = $configuredBy;
}
}
......@@ -2,7 +2,7 @@
declare(strict_types=1);
namespace Drupal\eu_oss_catalogue\Annotation;
namespace Drupal\eu_oss_catalogue\Attribute;
use Attribute;
use Drupal\Component\Annotation\Plugin;
......@@ -26,4 +26,13 @@ class EuOssCatalogueResolver extends Plugin {
*/
public Translation $label;
/**
* @param string $id
* @param \Drupal\Core\Annotation\Translation $label
*/
public function __construct(string $id, Translation $label) {
$this->id = $id;
$this->label = $label;
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment