ldc-arcadia-kiota-openapi-c.../client/Models/IncoBrand.php

132 lines
3.7 KiB
PHP

<?php
declare(strict_types=1);
namespace Uwil\ArcadiaKiotaOpenApiClient\Models;
use Microsoft\Kiota\Abstractions\Serialization\AdditionalDataHolder;
use Microsoft\Kiota\Abstractions\Serialization\Parsable;
use Microsoft\Kiota\Abstractions\Serialization\ParseNode;
use Microsoft\Kiota\Abstractions\Serialization\SerializationWriter;
/**
* Marque associée à la fiche produit INCO.
*/
class IncoBrand implements AdditionalDataHolder, Parsable
{
/**
* @var array<string, mixed>|null Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
*/
private ?array $additionalData = null;
/**
* @var string|null The code property
*/
private ?string $code = null;
/**
* @var string|null The label property
*/
private ?string $label = null;
/**
* Instantiates a new IncoBrand and sets the default values.
*/
public function __construct()
{
$this->setAdditionalData([]);
}
/**
* Creates a new instance of the appropriate class based on discriminator value
*
* @param ParseNode $parseNode The parse node to use to read the discriminator value and create the object
*/
public static function createFromDiscriminatorValue(ParseNode $parseNode): IncoBrand
{
return new IncoBrand();
}
/**
* Gets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
*
* @return array<string, mixed>|null
*/
public function getAdditionalData(): ?array
{
return $this->additionalData;
}
/**
* Gets the code property value. The code property
*/
public function getCode(): ?string
{
return $this->code;
}
/**
* The deserialization information for the current model
*
* @return array<string, callable(ParseNode): void>
*/
public function getFieldDeserializers(): array
{
$o = $this;
return [
'code' => fn (ParseNode $n) => $o->setCode($n->getStringValue()),
'label' => fn (ParseNode $n) => $o->setLabel($n->getStringValue()),
];
}
/**
* Gets the label property value. The label property
*/
public function getLabel(): ?string
{
return $this->label;
}
/**
* Serializes information the current object
*
* @param SerializationWriter $writer Serialization writer to use to serialize this model
*/
public function serialize(SerializationWriter $writer): void
{
$writer->writeStringValue('code', $this->getCode());
$writer->writeStringValue('label', $this->getLabel());
$writer->writeAdditionalData($this->getAdditionalData());
}
/**
* Sets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
*
* @param array<string,mixed> $value Value to set for the AdditionalData property.
*/
public function setAdditionalData(?array $value): void
{
$this->additionalData = $value;
}
/**
* Sets the code property value. The code property
*
* @param string|null $value Value to set for the code property.
*/
public function setCode(?string $value): void
{
$this->code = $value;
}
/**
* Sets the label property value. The label property
*
* @param string|null $value Value to set for the label property.
*/
public function setLabel(?string $value): void
{
$this->label = $value;
}
}