Moved Component.php to InternalComponent.php

This commit is contained in:
Netkas 2023-09-26 17:35:52 -04:00
parent 9aba1cbf38
commit d5c0ebf9c7
No known key found for this signature in database
GPG key ID: 5DAF58535614062B
2 changed files with 27 additions and 28 deletions

View file

@ -22,7 +22,7 @@
/** @noinspection PhpMissingFieldTypeInspection */ /** @noinspection PhpMissingFieldTypeInspection */
namespace ncc\Objects\NccVersionInformation; namespace ncc\Objects;
use ncc\Exceptions\IOException; use ncc\Exceptions\IOException;
use ncc\Exceptions\PathNotFoundException; use ncc\Exceptions\PathNotFoundException;
@ -30,7 +30,7 @@
use ncc\Utilities\IO; use ncc\Utilities\IO;
use RuntimeException; use RuntimeException;
class Component implements SerializableObjectInterface class InternalComponent implements SerializableObjectInterface
{ {
/** /**
* The Vendor of the component * The Vendor of the component
@ -99,9 +99,9 @@
* Constructs an object from an array representation * Constructs an object from an array representation
* *
* @param array $data * @param array $data
* @return Component * @return InternalComponent
*/ */
public static function fromArray(array $data): Component public static function fromArray(array $data): InternalComponent
{ {
$object = new self(); $object = new self();

View file

@ -25,7 +25,6 @@
namespace ncc\Objects; namespace ncc\Objects;
use ncc\Interfaces\SerializableObjectInterface; use ncc\Interfaces\SerializableObjectInterface;
use ncc\Objects\NccVersionInformation\Component;
class NccVersionInformation implements SerializableObjectInterface class NccVersionInformation implements SerializableObjectInterface
{ {
@ -53,7 +52,7 @@
/** /**
* An array of components that ncc uses and comes pre-built with * An array of components that ncc uses and comes pre-built with
* *
* @var Component[] * @var InternalComponent[]
*/ */
private $components; private $components;
@ -114,7 +113,7 @@
} }
/** /**
* @return Component[] * @return InternalComponent[]
*/ */
public function getComponents(): array public function getComponents(): array
{ {
@ -122,7 +121,7 @@
} }
/** /**
* @param Component[] $components * @param InternalComponent[] $components
*/ */
public function setComponents(array $components): void public function setComponents(array $components): void
{ {
@ -191,7 +190,7 @@
{ {
foreach($data['components'] as $datum) foreach($data['components'] as $datum)
{ {
$object->components[] = Component::fromArray($datum); $object->components[] = InternalComponent::fromArray($datum);
} }
} }